From 9cf22176b641c5979878f43c99687e20f2708605 Mon Sep 17 00:00:00 2001 From: Rajat Bajaj Date: Fri, 16 Aug 2024 11:33:33 +0530 Subject: [PATCH] Updated recordings and test cases --- management/organization_test.go | 30 +- management/resource_server_test.go | 14 +- .../TestClientGrantManager_Create.yaml | 461 +++++------ .../TestClientGrantManager_Delete.yaml | 602 +++++++------- .../TestClientGrantManager_List.yaml | 532 ++++++------- .../TestClientGrantManager_Organizations.yaml | 746 +++++++++--------- .../TestClientGrantManager_Read.yaml | 532 ++++++------- .../TestClientGrantManager_Update.yaml | 533 ++++++------- ...ganizationManager_ClientGrantsWithOrg.yaml | 141 ++-- .../recordings/TestResourceServer_List.yaml | 26 +- 10 files changed, 1689 insertions(+), 1928 deletions(-) diff --git a/management/organization_test.go b/management/organization_test.go index d933c7b0..102875e1 100644 --- a/management/organization_test.go +++ b/management/organization_test.go @@ -7,6 +7,7 @@ import ( "net/http" "os" "testing" + "time" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" @@ -480,12 +481,23 @@ func TestOrganizationManager_ClientGrantsWithOrg(t *testing.T) { org := givenAnOrganization(t) resourceServer := givenAResourceServer(t) - client := givenAClient(t) - client.DefaultOrganization = &DefaultOrganization{ - &[]string{"client_credentials"}, - auth0.String(org.GetID()), + client := &Client{ + Name: auth0.Stringf("Test Client (%s)", time.Now().Format(time.StampMilli)), + Description: auth0.String("This is just a test client."), + OrganizationUsage: auth0.String("allow"), + DefaultOrganization: &DefaultOrganization{ + &[]string{"client_credentials"}, + auth0.String(org.GetID()), + }, } + err := api.Client.Create(context.Background(), client) + require.NoError(t, err) + + t.Cleanup(func() { + cleanupClient(t, client.GetClientID()) + }) + clientGrant := &ClientGrant{ ClientID: client.ClientID, Audience: resourceServer.Identifier, @@ -494,7 +506,7 @@ func TestOrganizationManager_ClientGrantsWithOrg(t *testing.T) { OrganizationUsage: auth0.String("allow"), } - err := api.ClientGrant.Create(context.Background(), clientGrant) + err = api.ClientGrant.Create(context.Background(), clientGrant) require.NoError(t, err) t.Cleanup(func() { cleanupClientGrant(t, clientGrant.GetID()) @@ -505,19 +517,15 @@ func TestOrganizationManager_ClientGrantsWithOrg(t *testing.T) { associatedGrants, err := api.Organization.ClientGrants(context.Background(), org.GetID(), Parameter("grant_ids", clientGrant.GetID())) require.NoError(t, err) - assert.Len(t, associatedGrants.ClientGrants, 1) + assert.Greater(t, len(associatedGrants.ClientGrants), 0) assert.Equal(t, clientGrant.GetID(), associatedGrants.ClientGrants[0].GetID()) clients, err := api.Client.List(context.Background(), Parameter("q", fmt.Sprintf("client_grant.organization_id:%s", org.GetID()))) require.NoError(t, err) - assert.Equal(t, clients.Clients[0].GetClientID(), client.GetClientID()) + assert.Equal(t, client.GetClientID(), clients.Clients[0].GetClientID()) err = api.Organization.RemoveClientGrant(context.Background(), org.GetID(), clientGrant.GetID()) require.NoError(t, err) - - associatedGrants, err = api.Organization.ClientGrants(context.Background(), org.GetID()) - require.NoError(t, err) - assert.Len(t, associatedGrants.ClientGrants, 0) } func givenAnOrganization(t *testing.T) *Organization { diff --git a/management/resource_server_test.go b/management/resource_server_test.go index c4d0450e..1d102e11 100644 --- a/management/resource_server_test.go +++ b/management/resource_server_test.go @@ -220,11 +220,11 @@ func TestResourceServer_List(t *testing.T) { configureHTTPTestRecordings(t) expectedResourceServer := givenAResourceServer(t) - - resourceServerList, err := api.ResourceServer.List(context.Background(), IncludeFields("id")) - + resourceServerList, err := api.ResourceServer.List(context.Background(), IncludeFields("id", "identifier"), Parameter("identifiers", expectedResourceServer.GetIdentifier())) + require.NoError(t, err) + assert.NotEqual(t, len(resourceServerList.ResourceServers), 0) assert.NoError(t, err) - assert.Contains(t, resourceServerList.ResourceServers, &ResourceServer{ID: expectedResourceServer.ID}) + assert.Contains(t, resourceServerList.ResourceServers, &ResourceServer{ID: expectedResourceServer.ID, Identifier: expectedResourceServer.Identifier}) } func givenAResourceServer(t *testing.T) *ResourceServer { @@ -253,12 +253,6 @@ func givenAResourceServer(t *testing.T) *ResourceServer { err := api.ResourceServer.Create(context.Background(), resourceServer) require.NoError(t, err) - resourceServerList, err := api.ResourceServer.List(context.Background(), Parameter("identifiers", resourceServer.GetIdentifier())) - require.NoError(t, err) - assert.NotEqual(t, len(resourceServerList.ResourceServers), 0) - - assert.Equal(t, resourceServerList.ResourceServers[0].GetIdentifier(), resourceServer.GetIdentifier()) - t.Cleanup(func() { cleanupResourceServer(t, resourceServer.GetID()) }) diff --git a/test/data/recordings/TestClientGrantManager_Create.yaml b/test/data/recordings/TestClientGrantManager_Create.yaml index 5e580714..cf5bcec7 100644 --- a/test/data/recordings/TestClientGrantManager_Create.yaml +++ b/test/data/recordings/TestClientGrantManager_Create.yaml @@ -1,251 +1,216 @@ --- version: 2 interactions: - - id: 0 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 1125 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Client (Aug 13 15:33:44.275)","description":"This is just a test client.","jwt_configuration":{"alg":"RS256"},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"name":"Test Credential (Aug 13 15:33:44.275)","credential_type":"public_key","pem":"-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAua6LXMfgDE/tDdkOL1Oe\n3oWUwg1r4dSTg9L7RCcI5hItUzmkVofHtWN0H4CH2lm2ANmaJUsnhzctYowYW2+R\ntHvU9afTmtbdhpy993972hUqZSYLsE3iGziphYkOKVsqq38+VRH3TNg93zSLoRao\nJnTTkMXseVqiyqYRmFN8+gQQoEclHSGPUWQG5XMZ+hhuXeFyo+Yw/qbZWca/6/2I\n3rsca9jXR1alhxhHrXrg8N4Dm3gBgGbmiht6YYYT2Tyl1OqB9+iOI/9D7dfoCF6X\nAWJXRE454cmC8k8oucpjZVpflA+ocKshwPDR6YTLQYbXYiaWxEoaz0QGUErNQBnG\nI+sr9jDY3ua/s6HF6h0qyi/HVZH4wx+m4CtOfJoYTjrGBbaRszzUxhtSN2/MhXDu\n+a35q9/2zcu/3fjkkfVvGUt+NyyiYOKQ9vsJC1g/xxdUWtowjNwjfZE2zcG4usi8\nr38Bp0lmiipAsMLduZM/D5dFXkRdWCBNDfULmmg/4nv2wwjbjQuLemAMh7mmrztW\ni/85WMnjKQZT8NqS43pmgyIzg1gK1neMqdS90YmQ/PvJ36qALxCs245w1JpN9BAL\nJbwxCg/dbmKT7PalfWrksx9hGcJxtGqebldaOpw+5GVIPxxtC1C0gVr9BKeiDS3f\naibASY5pIRiKENmbZELDtucCAwEAAQ==\n-----END PUBLIC KEY-----"}]}}} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: false - body: '{"name":"Test Client (Aug 13 15:33:44.275)","description":"This is just a test client.","client_id":"joveONpXOKfCxEH29SCppk1jn0DpzlIW","client_secret":"[REDACTED]","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"alg":"RS256"},"signing_keys":[{"cert":"[REDACTED]"}],"sso_disabled":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"id":"cred_2ZcQcAyW53TMKoEUcvUrdi","name":"Test Credential (Aug 13 15:33:44.275)","kid":"4e7yYf0TKdyTLbVnpq2wLN6mZ8t7eb9UJkMksyHj9iU","credential_type":"public_key","alg":"RS256","created_at":"2024-08-13T10:03:45.227Z","updated_at":"2024-08-13T10:03:45.227Z"}]}}}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 1.131033958s - - id: 1 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 382 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Resource Server (Aug 13 15:33:45.409)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600,"enforce_policies":false,"token_dialect":"access_token"} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 550 - uncompressed: false - body: '{"id":"66bb2f8112949e6aec64699c","name":"Test Resource Server (Aug 13 15:33:45.409)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false,"enforce_policies":false,"token_dialect":"access_token"}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 367.021875ms - - id: 2 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers?identifiers=https%3A%2F%2Fapi.example.com%2F&include_totals=true&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"total":1,"start":0,"limit":50,"resource_servers":[{"id":"66bb2f8112949e6aec64699c","name":"Test Resource Server (Aug 13 15:33:45.409)","identifier":"https://api.example.com/","allow_offline_access":false,"skip_consent_for_verifiable_first_party_clients":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"signing_alg":"HS256","signing_secret":"bA9jsqRgKzBvZ6P98yw6SwM23UaITrLR","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"enforce_policies":false,"token_dialect":"access_token"}]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 341.910334ms - - id: 3 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 115 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"client_id":"joveONpXOKfCxEH29SCppk1jn0DpzlIW","audience":"https://api.example.com/","scope":["create:resource"]} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 142 - uncompressed: false - body: '{"id":"cgr_3wNiayIfIfAn4ayE","client_id":"joveONpXOKfCxEH29SCppk1jn0DpzlIW","audience":"https://api.example.com/","scope":["create:resource"]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 396.685959ms - - id: 4 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_3wNiayIfIfAn4ayE - 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: 342.560125ms - - id: 5 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/66bb2f8112949e6aec64699c - 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: 397.688459ms - - id: 6 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/joveONpXOKfCxEH29SCppk1jn0DpzlIW - 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: 384.882541ms + - id: 0 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 118 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Client (Jan 25 18:42:53.476)","description":"This is just a test client.","organization_usage":"allow"} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: false + body: '{"name":"Test Client (Jan 25 18:42:53.476)","description":"This is just a test client.","client_id":"reZA7oXxV3QIZv8o2i8GJFLFMaDJ2mBy","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"lifetime_in_seconds":36000},"sso_disabled":false,"cross_origin_auth":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 351.163667ms + - id: 1 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 239 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Resource Server (Jan 25 18:42:53.828)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 407 + uncompressed: false + body: '{"id":"63d16a1e092b3b8a8e4512b5","name":"Test Resource Server (Jan 25 18:42:53.828)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 104.999625ms + - id: 2 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 115 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"client_id":"reZA7oXxV3QIZv8o2i8GJFLFMaDJ2mBy","audience":"https://api.example.com/","scope":["create:resource"]} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 142 + uncompressed: false + body: '{"id":"cgr_hG5VSaXAejRTrTbz","client_id":"reZA7oXxV3QIZv8o2i8GJFLFMaDJ2mBy","audience":"https://api.example.com/","scope":["create:resource"]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 93.178375ms + - id: 3 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_hG5VSaXAejRTrTbz + 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: 106.390916ms + - id: 4 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/63d16a1e092b3b8a8e4512b5 + 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: 200.200375ms + - id: 5 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/reZA7oXxV3QIZv8o2i8GJFLFMaDJ2mBy + 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: 164.821083ms \ No newline at end of file diff --git a/test/data/recordings/TestClientGrantManager_Delete.yaml b/test/data/recordings/TestClientGrantManager_Delete.yaml index b77f6729..8f5acfbb 100644 --- a/test/data/recordings/TestClientGrantManager_Delete.yaml +++ b/test/data/recordings/TestClientGrantManager_Delete.yaml @@ -1,321 +1,287 @@ --- version: 2 interactions: - - id: 0 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 1125 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Client (Aug 13 15:34:25.885)","description":"This is just a test client.","jwt_configuration":{"alg":"RS256"},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"name":"Test Credential (Aug 13 15:34:25.885)","credential_type":"public_key","pem":"-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAua6LXMfgDE/tDdkOL1Oe\n3oWUwg1r4dSTg9L7RCcI5hItUzmkVofHtWN0H4CH2lm2ANmaJUsnhzctYowYW2+R\ntHvU9afTmtbdhpy993972hUqZSYLsE3iGziphYkOKVsqq38+VRH3TNg93zSLoRao\nJnTTkMXseVqiyqYRmFN8+gQQoEclHSGPUWQG5XMZ+hhuXeFyo+Yw/qbZWca/6/2I\n3rsca9jXR1alhxhHrXrg8N4Dm3gBgGbmiht6YYYT2Tyl1OqB9+iOI/9D7dfoCF6X\nAWJXRE454cmC8k8oucpjZVpflA+ocKshwPDR6YTLQYbXYiaWxEoaz0QGUErNQBnG\nI+sr9jDY3ua/s6HF6h0qyi/HVZH4wx+m4CtOfJoYTjrGBbaRszzUxhtSN2/MhXDu\n+a35q9/2zcu/3fjkkfVvGUt+NyyiYOKQ9vsJC1g/xxdUWtowjNwjfZE2zcG4usi8\nr38Bp0lmiipAsMLduZM/D5dFXkRdWCBNDfULmmg/4nv2wwjbjQuLemAMh7mmrztW\ni/85WMnjKQZT8NqS43pmgyIzg1gK1neMqdS90YmQ/PvJ36qALxCs245w1JpN9BAL\nJbwxCg/dbmKT7PalfWrksx9hGcJxtGqebldaOpw+5GVIPxxtC1C0gVr9BKeiDS3f\naibASY5pIRiKENmbZELDtucCAwEAAQ==\n-----END PUBLIC KEY-----"}]}}} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: false - body: '{"name":"Test Client (Aug 13 15:34:25.885)","description":"This is just a test client.","client_id":"uGdvxZOHGILccMkpte1co046wiwx7zJs","client_secret":"[REDACTED]","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"alg":"RS256"},"signing_keys":[{"cert":"[REDACTED]"}],"sso_disabled":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"id":"cred_weamKcKdgYov1sPXvASJuq","name":"Test Credential (Aug 13 15:34:25.885)","kid":"4e7yYf0TKdyTLbVnpq2wLN6mZ8t7eb9UJkMksyHj9iU","credential_type":"public_key","alg":"RS256","created_at":"2024-08-13T10:04:26.168Z","updated_at":"2024-08-13T10:04:26.168Z"}]}}}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 458.300542ms - - id: 1 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 382 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Resource Server (Aug 13 15:34:26.344)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600,"enforce_policies":false,"token_dialect":"access_token"} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 550 - uncompressed: false - body: '{"id":"66bb2faaa5e5fdad3d1c8a19","name":"Test Resource Server (Aug 13 15:34:26.344)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false,"enforce_policies":false,"token_dialect":"access_token"}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 458.925792ms - - id: 2 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers?identifiers=https%3A%2F%2Fapi.example.com%2F&include_totals=true&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"total":1,"start":0,"limit":50,"resource_servers":[{"id":"66bb2faaa5e5fdad3d1c8a19","name":"Test Resource Server (Aug 13 15:34:26.344)","identifier":"https://api.example.com/","allow_offline_access":false,"skip_consent_for_verifiable_first_party_clients":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"signing_alg":"HS256","signing_secret":"UE5UxRevhQDGopiatNhHp89v6nSdBKZt","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"enforce_policies":false,"token_dialect":"access_token"}]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 366.212625ms - - id: 3 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 115 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"client_id":"uGdvxZOHGILccMkpte1co046wiwx7zJs","audience":"https://api.example.com/","scope":["create:resource"]} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 142 - uncompressed: false - body: '{"id":"cgr_qc3pa7YcMViZUiT2","client_id":"uGdvxZOHGILccMkpte1co046wiwx7zJs","audience":"https://api.example.com/","scope":["create:resource"]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 323.035209ms - - id: 4 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_qc3pa7YcMViZUiT2 - 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: 390.978083ms - - id: 5 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants?include_totals=true&page=0&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"total":5,"start":0,"limit":50,"client_grants":[{"id":"cgr_2KSZblqq2lAppTi0","client_id":"TIMif4efChlXbeJSFZl0ZDI250naRRDM","audience":"https://go-auth0-dev.eu.auth0.com.sus.auth0.com/api/v2/","scope":["create:resource","create:organization_client_grants"]},{"id":"cgr_NBquE7kIO1ylN49N","client_id":"oPhW039ffKq0dA1D1cXbaRtPngIc2xJA","audience":"https://go-auth0-dev.eu.auth0.com.sus.auth0.com/api/v2/","scope":["create:resource","create:organization_client_grants"]},{"id":"cgr_UWYceavPkwfRPtbf","client_id":"Mt2OyVN7QphPhmFWgJMXtzzethEatko0","audience":"https://go-auth0-dev.eu.auth0.com.sus.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations_summary","create:authentication_methods","read:authentication_methods","update:authentication_methods","delete:authentication_methods","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations","read:scim_config","create:scim_config","update:scim_config","delete:scim_config","create:scim_token","read:scim_token","delete:scim_token","delete:phone_providers","create:phone_providers","read:phone_providers","update:phone_providers","delete:phone_templates","create:phone_templates","read:phone_templates","update:phone_templates","create:encryption_keys","read:encryption_keys","update:encryption_keys","delete:encryption_keys","read:sessions","delete:sessions","read:refresh_tokens","delete:refresh_tokens","create:self_service_profiles","read:self_service_profiles","update:self_service_profiles","delete:self_service_profiles","create:sso_access_tickets","read:forms","update:forms","delete:forms","create:forms","read:flows","update:flows","delete:flows","create:flows","read:flows_vault","update:flows_vault","delete:flows_vault","create:flows_vault","read:flows_executions","delete:flows_executions","read:client_credentials","create:client_credentials","update:client_credentials","delete:client_credentials","read:organization_client_grants","create:organization_client_grants","delete:organization_client_grants","update:device_codes","read:device_codes"]},{"id":"cgr_UhJJQSpHM7HovSzk","client_id":"MIToD9xBxaoP4NwHGKo2EJWwSU04Uxod","audience":"https://go-auth0-dev.eu.auth0.com.sus.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations_summary","create:authentication_methods","read:authentication_methods","update:authentication_methods","delete:authentication_methods","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations","read:scim_config","create:scim_config","update:scim_config","delete:scim_config","create:scim_token","read:scim_token","delete:scim_token","delete:phone_providers","create:phone_providers","read:phone_providers","update:phone_providers","delete:phone_templates","create:phone_templates","read:phone_templates","update:phone_templates","create:encryption_keys","read:encryption_keys","update:encryption_keys","delete:encryption_keys","read:sessions","delete:sessions","read:refresh_tokens","delete:refresh_tokens","create:self_service_profiles","read:self_service_profiles","update:self_service_profiles","delete:self_service_profiles","create:sso_access_tickets","read:forms","update:forms","delete:forms","create:forms","read:flows","update:flows","delete:flows","create:flows","read:flows_vault","update:flows_vault","delete:flows_vault","create:flows_vault","read:client_credentials","create:client_credentials","update:client_credentials","delete:client_credentials","update:device_codes","read:device_codes"]},{"id":"cgr_zV8sbywGQQxCnreD","client_id":"bpViNbMMF1X5J17kaB1jObShEVB81nol","audience":"https://go-auth0-dev.eu.auth0.com.sus.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations_summary","create:authentication_methods","read:authentication_methods","update:authentication_methods","delete:authentication_methods","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations","read:scim_config","create:scim_config","update:scim_config","delete:scim_config","create:scim_token","read:scim_token","delete:scim_token","delete:phone_providers","create:phone_providers","read:phone_providers","update:phone_providers","delete:phone_templates","create:phone_templates","read:phone_templates","update:phone_templates","create:encryption_keys","read:encryption_keys","update:encryption_keys","delete:encryption_keys","read:sessions","delete:sessions","read:refresh_tokens","delete:refresh_tokens","create:self_service_profiles","read:self_service_profiles","update:self_service_profiles","delete:self_service_profiles","create:sso_access_tickets","read:forms","update:forms","delete:forms","create:forms","read:flows","update:flows","delete:flows","create:flows","read:flows_vault","update:flows_vault","delete:flows_vault","create:flows_vault","read:flows_executions","delete:flows_executions","read:client_credentials","create:client_credentials","update:client_credentials","delete:client_credentials","read:organization_client_grants","create:organization_client_grants","delete:organization_client_grants","update:device_codes","read:device_codes"]}]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 409.556208ms - - id: 6 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_qc3pa7YcMViZUiT2 - 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: 410.074709ms - - id: 7 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/66bb2faaa5e5fdad3d1c8a19 - 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: 354.024666ms - - id: 8 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/uGdvxZOHGILccMkpte1co046wiwx7zJs - 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: 360.153875ms + - id: 0 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 118 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Client (Jan 25 18:43:02.828)","description":"This is just a test client.","organization_usage":"allow"} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: false + body: '{"name":"Test Client (Jan 25 18:43:02.828)","description":"This is just a test client.","client_id":"YYwuclX0kGj5vBx0gmnSCk0BzxFvws3i","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"lifetime_in_seconds":36000},"sso_disabled":false,"cross_origin_auth":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 337.027833ms + - id: 1 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 239 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Resource Server (Jan 25 18:43:03.165)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 407 + uncompressed: false + body: '{"id":"63d16a2767746e50f974b071","name":"Test Resource Server (Jan 25 18:43:03.165)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 106.217ms + - id: 2 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 115 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"client_id":"YYwuclX0kGj5vBx0gmnSCk0BzxFvws3i","audience":"https://api.example.com/","scope":["create:resource"]} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 142 + uncompressed: false + body: '{"id":"cgr_H4oSB3BqNwe31qoL","client_id":"YYwuclX0kGj5vBx0gmnSCk0BzxFvws3i","audience":"https://api.example.com/","scope":["create:resource"]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 99.201083ms + - id: 3 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_H4oSB3BqNwe31qoL + 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: 116.702ms + - id: 4 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [] + trailer: {} + host: go-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://go-auth0-dev.eu.auth0.com/api/v2/client-grants?include_totals=true&page=0&per_page=50 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: true + body: '{"total":5,"start":0,"limit":50,"client_grants":[{"id":"cgr_DrgPYSBkPAEFt6Yb","client_id":"Z3FKRhWMsXg7iwljDHcNtAkUnCRXYttO","audience":"https://go-auth0-dev.eu.auth0.com.eu.auth0.com/api/v2/","scope":[]},{"id":"cgr_EjTJshin5ruIvPqh","client_id":"3tjbn4dFI04fpHKnVlGs1GYDzQKIEmbF","audience":"https://go-auth0-dev.eu.auth0.com.eu.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations","read:organizations_summary","create:actions_log_sessions","create:authentication_methods","read:authentication_methods","update:authentication_methods","delete:authentication_methods"]},{"id":"cgr_F4BqCN0e5Grfa2Nj","client_id":"uRWKdiFmUEC3Kohfpq4HKjgKe26ynMSj","audience":"https://go-auth0-dev.eu.auth0.com.eu.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations_summary","create:actions_log_sessions","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations"]},{"id":"cgr_ZK11IyPr7cZLYwqC","client_id":"O6L9dP0GnD10qe4NVE6K67PiDEHxZEid","audience":"https://go-auth0-dev.eu.auth0.com.eu.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations"]},{"id":"cgr_r65kKhuS0nFMavVE","client_id":"8IgJbmEeGNsF7A4GXnYaiO6hScFYMjAv","audience":"https://go-auth0-dev.eu.auth0.com.eu.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations_summary","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations"]}]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 6.249001708s + - id: 5 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_H4oSB3BqNwe31qoL + 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: 103.803792ms + - id: 6 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/63d16a2767746e50f974b071 + 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: 119.162958ms + - id: 7 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/YYwuclX0kGj5vBx0gmnSCk0BzxFvws3i + 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: 158.591ms \ No newline at end of file diff --git a/test/data/recordings/TestClientGrantManager_List.yaml b/test/data/recordings/TestClientGrantManager_List.yaml index c2603de4..28d1a4a2 100644 --- a/test/data/recordings/TestClientGrantManager_List.yaml +++ b/test/data/recordings/TestClientGrantManager_List.yaml @@ -1,286 +1,252 @@ --- version: 2 interactions: - - id: 0 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 1125 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Client (Aug 13 15:34:29.427)","description":"This is just a test client.","jwt_configuration":{"alg":"RS256"},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"name":"Test Credential (Aug 13 15:34:29.427)","credential_type":"public_key","pem":"-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAua6LXMfgDE/tDdkOL1Oe\n3oWUwg1r4dSTg9L7RCcI5hItUzmkVofHtWN0H4CH2lm2ANmaJUsnhzctYowYW2+R\ntHvU9afTmtbdhpy993972hUqZSYLsE3iGziphYkOKVsqq38+VRH3TNg93zSLoRao\nJnTTkMXseVqiyqYRmFN8+gQQoEclHSGPUWQG5XMZ+hhuXeFyo+Yw/qbZWca/6/2I\n3rsca9jXR1alhxhHrXrg8N4Dm3gBgGbmiht6YYYT2Tyl1OqB9+iOI/9D7dfoCF6X\nAWJXRE454cmC8k8oucpjZVpflA+ocKshwPDR6YTLQYbXYiaWxEoaz0QGUErNQBnG\nI+sr9jDY3ua/s6HF6h0qyi/HVZH4wx+m4CtOfJoYTjrGBbaRszzUxhtSN2/MhXDu\n+a35q9/2zcu/3fjkkfVvGUt+NyyiYOKQ9vsJC1g/xxdUWtowjNwjfZE2zcG4usi8\nr38Bp0lmiipAsMLduZM/D5dFXkRdWCBNDfULmmg/4nv2wwjbjQuLemAMh7mmrztW\ni/85WMnjKQZT8NqS43pmgyIzg1gK1neMqdS90YmQ/PvJ36qALxCs245w1JpN9BAL\nJbwxCg/dbmKT7PalfWrksx9hGcJxtGqebldaOpw+5GVIPxxtC1C0gVr9BKeiDS3f\naibASY5pIRiKENmbZELDtucCAwEAAQ==\n-----END PUBLIC KEY-----"}]}}} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: false - body: '{"name":"Test Client (Aug 13 15:34:29.427)","description":"This is just a test client.","client_id":"HeF0V6QysNwAL59UdT9vE8QVyCYwN5Ra","client_secret":"[REDACTED]","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"alg":"RS256"},"signing_keys":[{"cert":"[REDACTED]"}],"sso_disabled":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"id":"cred_ikPNoZdGW6ZhBrnDsCYkAS","name":"Test Credential (Aug 13 15:34:29.427)","kid":"4e7yYf0TKdyTLbVnpq2wLN6mZ8t7eb9UJkMksyHj9iU","credential_type":"public_key","alg":"RS256","created_at":"2024-08-13T10:04:29.689Z","updated_at":"2024-08-13T10:04:29.689Z"}]}}}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 470.620042ms - - id: 1 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 382 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Resource Server (Aug 13 15:34:29.899)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600,"enforce_policies":false,"token_dialect":"access_token"} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 550 - uncompressed: false - body: '{"id":"66bb2faea5e5fdad3d1c8a1a","name":"Test Resource Server (Aug 13 15:34:29.899)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false,"enforce_policies":false,"token_dialect":"access_token"}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 351.209166ms - - id: 2 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers?identifiers=https%3A%2F%2Fapi.example.com%2F&include_totals=true&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"total":1,"start":0,"limit":50,"resource_servers":[{"id":"66bb2faea5e5fdad3d1c8a1a","name":"Test Resource Server (Aug 13 15:34:29.899)","identifier":"https://api.example.com/","allow_offline_access":false,"skip_consent_for_verifiable_first_party_clients":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"signing_alg":"HS256","signing_secret":"WHM5IeiKnqfrKsuVRg2y09kKKglz5h2w","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"enforce_policies":false,"token_dialect":"access_token"}]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 466.497209ms - - id: 3 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 115 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"client_id":"HeF0V6QysNwAL59UdT9vE8QVyCYwN5Ra","audience":"https://api.example.com/","scope":["create:resource"]} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 142 - uncompressed: false - body: '{"id":"cgr_BCh7xrjp1gcBswc7","client_id":"HeF0V6QysNwAL59UdT9vE8QVyCYwN5Ra","audience":"https://api.example.com/","scope":["create:resource"]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 341.224875ms - - id: 4 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants?client_id=HeF0V6QysNwAL59UdT9vE8QVyCYwN5Ra&include_totals=true&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"total":1,"start":0,"limit":50,"client_grants":[{"id":"cgr_BCh7xrjp1gcBswc7","client_id":"HeF0V6QysNwAL59UdT9vE8QVyCYwN5Ra","audience":"https://api.example.com/","scope":["create:resource"]}]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 312.590958ms - - id: 5 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_BCh7xrjp1gcBswc7 - 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: 380.722ms - - id: 6 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/66bb2faea5e5fdad3d1c8a1a - 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: 431.722875ms - - id: 7 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/HeF0V6QysNwAL59UdT9vE8QVyCYwN5Ra - 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: 409.575458ms + - id: 0 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 118 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Client (Jan 25 18:43:10.125)","description":"This is just a test client.","organization_usage":"allow"} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: false + body: '{"name":"Test Client (Jan 25 18:43:10.125)","description":"This is just a test client.","client_id":"islY6yTOEAXx2oB1YRCI2BXrDf279Q2k","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"lifetime_in_seconds":36000},"sso_disabled":false,"cross_origin_auth":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 465.240625ms + - id: 1 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 239 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Resource Server (Jan 25 18:43:10.591)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 407 + uncompressed: false + body: '{"id":"63d16a2e5299c7ac2ed8e262","name":"Test Resource Server (Jan 25 18:43:10.591)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 97.081833ms + - id: 2 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 115 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"client_id":"islY6yTOEAXx2oB1YRCI2BXrDf279Q2k","audience":"https://api.example.com/","scope":["create:resource"]} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 142 + uncompressed: false + body: '{"id":"cgr_ELKvKN1Yf2gYGGyK","client_id":"islY6yTOEAXx2oB1YRCI2BXrDf279Q2k","audience":"https://api.example.com/","scope":["create:resource"]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 108.261125ms + - id: 3 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [] + trailer: {} + host: go-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://go-auth0-dev.eu.auth0.com/api/v2/client-grants?client_id=islY6yTOEAXx2oB1YRCI2BXrDf279Q2k&include_totals=true&per_page=50 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: true + body: '{"total":1,"start":0,"limit":50,"client_grants":[{"id":"cgr_ELKvKN1Yf2gYGGyK","client_id":"islY6yTOEAXx2oB1YRCI2BXrDf279Q2k","audience":"https://api.example.com/","scope":["create:resource"]}]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 98.526708ms + - id: 4 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_ELKvKN1Yf2gYGGyK + 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: 93.633833ms + - id: 5 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/63d16a2e5299c7ac2ed8e262 + 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: 209.032375ms + - id: 6 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/islY6yTOEAXx2oB1YRCI2BXrDf279Q2k + 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: 106.576917ms \ No newline at end of file diff --git a/test/data/recordings/TestClientGrantManager_Organizations.yaml b/test/data/recordings/TestClientGrantManager_Organizations.yaml index f0381998..1166a953 100644 --- a/test/data/recordings/TestClientGrantManager_Organizations.yaml +++ b/test/data/recordings/TestClientGrantManager_Organizations.yaml @@ -1,393 +1,359 @@ --- version: 2 interactions: - - id: 0 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 122 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"test-organization388","display_name":"Test Organization","branding":{"logo_url":"https://example.com/logo.gif"}} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 149 - uncompressed: false - body: '{"branding":{"logo_url":"https://example.com/logo.gif"},"id":"org_wJ4nUu65WIVwBGNu","display_name":"Test Organization","name":"test-organization388"}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 404.925708ms - - id: 1 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 1125 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Client (Aug 13 15:34:33.005)","description":"This is just a test client.","jwt_configuration":{"alg":"RS256"},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"name":"Test Credential (Aug 13 15:34:33.005)","credential_type":"public_key","pem":"-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAua6LXMfgDE/tDdkOL1Oe\n3oWUwg1r4dSTg9L7RCcI5hItUzmkVofHtWN0H4CH2lm2ANmaJUsnhzctYowYW2+R\ntHvU9afTmtbdhpy993972hUqZSYLsE3iGziphYkOKVsqq38+VRH3TNg93zSLoRao\nJnTTkMXseVqiyqYRmFN8+gQQoEclHSGPUWQG5XMZ+hhuXeFyo+Yw/qbZWca/6/2I\n3rsca9jXR1alhxhHrXrg8N4Dm3gBgGbmiht6YYYT2Tyl1OqB9+iOI/9D7dfoCF6X\nAWJXRE454cmC8k8oucpjZVpflA+ocKshwPDR6YTLQYbXYiaWxEoaz0QGUErNQBnG\nI+sr9jDY3ua/s6HF6h0qyi/HVZH4wx+m4CtOfJoYTjrGBbaRszzUxhtSN2/MhXDu\n+a35q9/2zcu/3fjkkfVvGUt+NyyiYOKQ9vsJC1g/xxdUWtowjNwjfZE2zcG4usi8\nr38Bp0lmiipAsMLduZM/D5dFXkRdWCBNDfULmmg/4nv2wwjbjQuLemAMh7mmrztW\ni/85WMnjKQZT8NqS43pmgyIzg1gK1neMqdS90YmQ/PvJ36qALxCs245w1JpN9BAL\nJbwxCg/dbmKT7PalfWrksx9hGcJxtGqebldaOpw+5GVIPxxtC1C0gVr9BKeiDS3f\naibASY5pIRiKENmbZELDtucCAwEAAQ==\n-----END PUBLIC KEY-----"}]}}} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: false - body: '{"name":"Test Client (Aug 13 15:34:33.005)","description":"This is just a test client.","client_id":"ndLldI2MLdpFUwNi0NpZeuMmL4hjU12o","client_secret":"[REDACTED]","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"alg":"RS256"},"signing_keys":[{"cert":"[REDACTED]"}],"sso_disabled":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"id":"cred_cpLYtfbuY9uxWRA3mjLDmN","name":"Test Credential (Aug 13 15:34:33.005)","kid":"4e7yYf0TKdyTLbVnpq2wLN6mZ8t7eb9UJkMksyHj9iU","credential_type":"public_key","alg":"RS256","created_at":"2024-08-13T10:04:33.262Z","updated_at":"2024-08-13T10:04:33.262Z"}]}}}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 480.569584ms - - id: 2 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 382 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Resource Server (Aug 13 15:34:33.487)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600,"enforce_policies":false,"token_dialect":"access_token"} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 550 - uncompressed: false - body: '{"id":"66bb2fb1a6233f1fc1166eeb","name":"Test Resource Server (Aug 13 15:34:33.487)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false,"enforce_policies":false,"token_dialect":"access_token"}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 365.897084ms - - id: 3 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers?identifiers=https%3A%2F%2Fapi.example.com%2F&include_totals=true&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"total":1,"start":0,"limit":50,"resource_servers":[{"id":"66bb2fb1a6233f1fc1166eeb","name":"Test Resource Server (Aug 13 15:34:33.487)","identifier":"https://api.example.com/","allow_offline_access":false,"skip_consent_for_verifiable_first_party_clients":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"signing_alg":"HS256","signing_secret":"tacylVUHf1josHgEKai96VZxgGfYxVlh","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"enforce_policies":false,"token_dialect":"access_token"}]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 347.813083ms - - id: 4 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 174 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"client_id":"ndLldI2MLdpFUwNi0NpZeuMmL4hjU12o","audience":"https://api.example.com/","scope":["create:resource"],"allow_any_organization":true,"organization_usage":"allow"} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 201 - uncompressed: false - body: '{"id":"cgr_mRRxhKgGOHUUOTbG","client_id":"ndLldI2MLdpFUwNi0NpZeuMmL4hjU12o","audience":"https://api.example.com/","scope":["create:resource"],"organization_usage":"allow","allow_any_organization":true}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 332.677583ms - - id: 5 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 36 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"grant_id":"cgr_mRRxhKgGOHUUOTbG"} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_wJ4nUu65WIVwBGNu/client-grants - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 148 - uncompressed: false - body: '{"grant_id":"cgr_mRRxhKgGOHUUOTbG","client_id":"ndLldI2MLdpFUwNi0NpZeuMmL4hjU12o","audience":"https://api.example.com/","scope":["create:resource"]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 378.048083ms - - id: 6 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_mRRxhKgGOHUUOTbG/organizations?include_totals=true&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"organizations":[{"id":"org_wJ4nUu65WIVwBGNu","name":"test-organization388","display_name":"Test Organization","branding":{"logo_url":"https://example.com/logo.gif"}}],"start":0,"limit":50,"total":1}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 392.297459ms - - id: 7 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_mRRxhKgGOHUUOTbG - 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: 389.692708ms - - id: 8 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/66bb2fb1a6233f1fc1166eeb - 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: 413.971167ms - - id: 9 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/ndLldI2MLdpFUwNi0NpZeuMmL4hjU12o - 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: 375.058166ms - - id: 10 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_wJ4nUu65WIVwBGNu - 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: 311.557041ms + - id: 0 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 122 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"test-organization248","display_name":"Test Organization","branding":{"logo_url":"https://example.com/logo.gif"}} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 149 + uncompressed: false + body: '{"name":"test-organization248","display_name":"Test Organization","branding":{"logo_url":"https://example.com/logo.gif"},"id":"org_OjbL69ZRTlpNCzsC"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 629.701542ms + - id: 1 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 1125 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Client (Nov 8 16:32:06.260)","description":"This is just a test client.","jwt_configuration":{"alg":"RS256"},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"name":"Test Credential (Nov 8 16:32:06.261)","credential_type":"public_key","pem":"-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAua6LXMfgDE/tDdkOL1Oe\n3oWUwg1r4dSTg9L7RCcI5hItUzmkVofHtWN0H4CH2lm2ANmaJUsnhzctYowYW2+R\ntHvU9afTmtbdhpy993972hUqZSYLsE3iGziphYkOKVsqq38+VRH3TNg93zSLoRao\nJnTTkMXseVqiyqYRmFN8+gQQoEclHSGPUWQG5XMZ+hhuXeFyo+Yw/qbZWca/6/2I\n3rsca9jXR1alhxhHrXrg8N4Dm3gBgGbmiht6YYYT2Tyl1OqB9+iOI/9D7dfoCF6X\nAWJXRE454cmC8k8oucpjZVpflA+ocKshwPDR6YTLQYbXYiaWxEoaz0QGUErNQBnG\nI+sr9jDY3ua/s6HF6h0qyi/HVZH4wx+m4CtOfJoYTjrGBbaRszzUxhtSN2/MhXDu\n+a35q9/2zcu/3fjkkfVvGUt+NyyiYOKQ9vsJC1g/xxdUWtowjNwjfZE2zcG4usi8\nr38Bp0lmiipAsMLduZM/D5dFXkRdWCBNDfULmmg/4nv2wwjbjQuLemAMh7mmrztW\ni/85WMnjKQZT8NqS43pmgyIzg1gK1neMqdS90YmQ/PvJ36qALxCs245w1JpN9BAL\nJbwxCg/dbmKT7PalfWrksx9hGcJxtGqebldaOpw+5GVIPxxtC1C0gVr9BKeiDS3f\naibASY5pIRiKENmbZELDtucCAwEAAQ==\n-----END PUBLIC KEY-----"}]}}} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: false + body: '{"name":"Test Client (Nov 8 16:32:06.260)","description":"This is just a test client.","client_id":"jsOdQrWgCpGCXsZ596k45Yba0pEXkmDG","client_secret":"[REDACTED]","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"alg":"RS256"},"signing_keys":[{"cert":"[REDACTED]"}],"sso_disabled":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"id":"cred_jL72fJDnj3nNGsbCoYvruj","name":"Test Credential (Nov 8 16:32:06.261)","kid":"4e7yYf0TKdyTLbVnpq2wLN6mZ8t7eb9UJkMksyHj9iU","credential_type":"public_key","alg":"RS256","created_at":"2023-11-08T16:32:06.505Z","updated_at":"2023-11-08T16:32:06.505Z"}]}}}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 463.235209ms + - id: 2 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 239 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Resource Server (Nov 8 16:32:06.726)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 407 + uncompressed: false + body: '{"id":"654bb8060c032297bf07ecaf","name":"Test Resource Server (Nov 8 16:32:06.726)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 266.637208ms + - id: 3 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 174 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"client_id":"jsOdQrWgCpGCXsZ596k45Yba0pEXkmDG","audience":"https://api.example.com/","scope":["create:resource"],"allow_any_organization":true,"organization_usage":"allow"} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 201 + uncompressed: false + body: '{"id":"cgr_MyWeQ2whciOYISER","client_id":"jsOdQrWgCpGCXsZ596k45Yba0pEXkmDG","audience":"https://api.example.com/","scope":["create:resource"],"organization_usage":"allow","allow_any_organization":true}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 278.980709ms + - id: 4 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 36 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"grant_id":"cgr_MyWeQ2whciOYISER"} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_OjbL69ZRTlpNCzsC/client-grants + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 148 + uncompressed: false + body: '{"grant_id":"cgr_MyWeQ2whciOYISER","client_id":"jsOdQrWgCpGCXsZ596k45Yba0pEXkmDG","audience":"https://api.example.com/","scope":["create:resource"]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 278.988083ms + - id: 5 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + null + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_MyWeQ2whciOYISER/organizations?include_totals=true&per_page=50 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: true + body: '{"organizations":[{"id":"org_OjbL69ZRTlpNCzsC","name":"test-organization248","display_name":"Test Organization","branding":{"logo_url":"https://example.com/logo.gif"}}],"start":0,"limit":50,"total":1}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 269.523041ms + - id: 6 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_MyWeQ2whciOYISER + 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: 348.420625ms + - id: 7 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/654bb8060c032297bf07ecaf + 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: 423.452375ms + - id: 8 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/jsOdQrWgCpGCXsZ596k45Yba0pEXkmDG + 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: 511.401708ms + - id: 9 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_OjbL69ZRTlpNCzsC + 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: 241.841375ms \ No newline at end of file diff --git a/test/data/recordings/TestClientGrantManager_Read.yaml b/test/data/recordings/TestClientGrantManager_Read.yaml index 674eb4ab..df631611 100644 --- a/test/data/recordings/TestClientGrantManager_Read.yaml +++ b/test/data/recordings/TestClientGrantManager_Read.yaml @@ -1,286 +1,252 @@ --- version: 2 interactions: - - id: 0 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 1125 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Client (Aug 13 15:34:18.414)","description":"This is just a test client.","jwt_configuration":{"alg":"RS256"},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"name":"Test Credential (Aug 13 15:34:18.414)","credential_type":"public_key","pem":"-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAua6LXMfgDE/tDdkOL1Oe\n3oWUwg1r4dSTg9L7RCcI5hItUzmkVofHtWN0H4CH2lm2ANmaJUsnhzctYowYW2+R\ntHvU9afTmtbdhpy993972hUqZSYLsE3iGziphYkOKVsqq38+VRH3TNg93zSLoRao\nJnTTkMXseVqiyqYRmFN8+gQQoEclHSGPUWQG5XMZ+hhuXeFyo+Yw/qbZWca/6/2I\n3rsca9jXR1alhxhHrXrg8N4Dm3gBgGbmiht6YYYT2Tyl1OqB9+iOI/9D7dfoCF6X\nAWJXRE454cmC8k8oucpjZVpflA+ocKshwPDR6YTLQYbXYiaWxEoaz0QGUErNQBnG\nI+sr9jDY3ua/s6HF6h0qyi/HVZH4wx+m4CtOfJoYTjrGBbaRszzUxhtSN2/MhXDu\n+a35q9/2zcu/3fjkkfVvGUt+NyyiYOKQ9vsJC1g/xxdUWtowjNwjfZE2zcG4usi8\nr38Bp0lmiipAsMLduZM/D5dFXkRdWCBNDfULmmg/4nv2wwjbjQuLemAMh7mmrztW\ni/85WMnjKQZT8NqS43pmgyIzg1gK1neMqdS90YmQ/PvJ36qALxCs245w1JpN9BAL\nJbwxCg/dbmKT7PalfWrksx9hGcJxtGqebldaOpw+5GVIPxxtC1C0gVr9BKeiDS3f\naibASY5pIRiKENmbZELDtucCAwEAAQ==\n-----END PUBLIC KEY-----"}]}}} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: false - body: '{"name":"Test Client (Aug 13 15:34:18.414)","description":"This is just a test client.","client_id":"oC4CSnxnDKKQuM9u5gdkjN4HykOEaTKc","client_secret":"[REDACTED]","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"alg":"RS256"},"signing_keys":[{"cert":"[REDACTED]"}],"sso_disabled":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"id":"cred_s6QQ9dzgHn3b3Ta5kVPYRL","name":"Test Credential (Aug 13 15:34:18.414)","kid":"4e7yYf0TKdyTLbVnpq2wLN6mZ8t7eb9UJkMksyHj9iU","credential_type":"public_key","alg":"RS256","created_at":"2024-08-13T10:04:19.261Z","updated_at":"2024-08-13T10:04:19.261Z"}]}}}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 1.086054167s - - id: 1 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 382 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Resource Server (Aug 13 15:34:19.501)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600,"enforce_policies":false,"token_dialect":"access_token"} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 550 - uncompressed: false - body: '{"id":"66bb2fa3a5e5fdad3d1c8a18","name":"Test Resource Server (Aug 13 15:34:19.501)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false,"enforce_policies":false,"token_dialect":"access_token"}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 416.557125ms - - id: 2 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers?identifiers=https%3A%2F%2Fapi.example.com%2F&include_totals=true&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"total":1,"start":0,"limit":50,"resource_servers":[{"id":"66bb2fa3a5e5fdad3d1c8a18","name":"Test Resource Server (Aug 13 15:34:19.501)","identifier":"https://api.example.com/","allow_offline_access":false,"skip_consent_for_verifiable_first_party_clients":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"signing_alg":"HS256","signing_secret":"bVBZXn530LJMswavbqvBE9YkmbwW641h","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"enforce_policies":false,"token_dialect":"access_token"}]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 492.104333ms - - id: 3 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 115 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"client_id":"oC4CSnxnDKKQuM9u5gdkjN4HykOEaTKc","audience":"https://api.example.com/","scope":["create:resource"]} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 142 - uncompressed: false - body: '{"id":"cgr_Z2I6ty0KpvCr0amy","client_id":"oC4CSnxnDKKQuM9u5gdkjN4HykOEaTKc","audience":"https://api.example.com/","scope":["create:resource"]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 408.455333ms - - id: 4 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants?include_totals=true&page=0&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"total":6,"start":0,"limit":50,"client_grants":[{"id":"cgr_2KSZblqq2lAppTi0","client_id":"TIMif4efChlXbeJSFZl0ZDI250naRRDM","audience":"https://go-auth0-dev.eu.auth0.com.sus.auth0.com/api/v2/","scope":["create:resource","create:organization_client_grants"]},{"id":"cgr_NBquE7kIO1ylN49N","client_id":"oPhW039ffKq0dA1D1cXbaRtPngIc2xJA","audience":"https://go-auth0-dev.eu.auth0.com.sus.auth0.com/api/v2/","scope":["create:resource","create:organization_client_grants"]},{"id":"cgr_UWYceavPkwfRPtbf","client_id":"Mt2OyVN7QphPhmFWgJMXtzzethEatko0","audience":"https://go-auth0-dev.eu.auth0.com.sus.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations_summary","create:authentication_methods","read:authentication_methods","update:authentication_methods","delete:authentication_methods","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations","read:scim_config","create:scim_config","update:scim_config","delete:scim_config","create:scim_token","read:scim_token","delete:scim_token","delete:phone_providers","create:phone_providers","read:phone_providers","update:phone_providers","delete:phone_templates","create:phone_templates","read:phone_templates","update:phone_templates","create:encryption_keys","read:encryption_keys","update:encryption_keys","delete:encryption_keys","read:sessions","delete:sessions","read:refresh_tokens","delete:refresh_tokens","create:self_service_profiles","read:self_service_profiles","update:self_service_profiles","delete:self_service_profiles","create:sso_access_tickets","read:forms","update:forms","delete:forms","create:forms","read:flows","update:flows","delete:flows","create:flows","read:flows_vault","update:flows_vault","delete:flows_vault","create:flows_vault","read:flows_executions","delete:flows_executions","read:client_credentials","create:client_credentials","update:client_credentials","delete:client_credentials","read:organization_client_grants","create:organization_client_grants","delete:organization_client_grants","update:device_codes","read:device_codes"]},{"id":"cgr_UhJJQSpHM7HovSzk","client_id":"MIToD9xBxaoP4NwHGKo2EJWwSU04Uxod","audience":"https://go-auth0-dev.eu.auth0.com.sus.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations_summary","create:authentication_methods","read:authentication_methods","update:authentication_methods","delete:authentication_methods","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations","read:scim_config","create:scim_config","update:scim_config","delete:scim_config","create:scim_token","read:scim_token","delete:scim_token","delete:phone_providers","create:phone_providers","read:phone_providers","update:phone_providers","delete:phone_templates","create:phone_templates","read:phone_templates","update:phone_templates","create:encryption_keys","read:encryption_keys","update:encryption_keys","delete:encryption_keys","read:sessions","delete:sessions","read:refresh_tokens","delete:refresh_tokens","create:self_service_profiles","read:self_service_profiles","update:self_service_profiles","delete:self_service_profiles","create:sso_access_tickets","read:forms","update:forms","delete:forms","create:forms","read:flows","update:flows","delete:flows","create:flows","read:flows_vault","update:flows_vault","delete:flows_vault","create:flows_vault","read:client_credentials","create:client_credentials","update:client_credentials","delete:client_credentials","update:device_codes","read:device_codes"]},{"id":"cgr_Z2I6ty0KpvCr0amy","client_id":"oC4CSnxnDKKQuM9u5gdkjN4HykOEaTKc","audience":"https://api.example.com/","scope":["create:resource"]},{"id":"cgr_zV8sbywGQQxCnreD","client_id":"bpViNbMMF1X5J17kaB1jObShEVB81nol","audience":"https://go-auth0-dev.eu.auth0.com.sus.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations_summary","create:authentication_methods","read:authentication_methods","update:authentication_methods","delete:authentication_methods","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations","read:scim_config","create:scim_config","update:scim_config","delete:scim_config","create:scim_token","read:scim_token","delete:scim_token","delete:phone_providers","create:phone_providers","read:phone_providers","update:phone_providers","delete:phone_templates","create:phone_templates","read:phone_templates","update:phone_templates","create:encryption_keys","read:encryption_keys","update:encryption_keys","delete:encryption_keys","read:sessions","delete:sessions","read:refresh_tokens","delete:refresh_tokens","create:self_service_profiles","read:self_service_profiles","update:self_service_profiles","delete:self_service_profiles","create:sso_access_tickets","read:forms","update:forms","delete:forms","create:forms","read:flows","update:flows","delete:flows","create:flows","read:flows_vault","update:flows_vault","delete:flows_vault","create:flows_vault","read:flows_executions","delete:flows_executions","read:client_credentials","create:client_credentials","update:client_credentials","delete:client_credentials","read:organization_client_grants","create:organization_client_grants","delete:organization_client_grants","update:device_codes","read:device_codes"]}]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 372.537125ms - - id: 5 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_Z2I6ty0KpvCr0amy - 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: 361.358ms - - id: 6 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/66bb2fa3a5e5fdad3d1c8a18 - 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: 493.02075ms - - id: 7 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/oC4CSnxnDKKQuM9u5gdkjN4HykOEaTKc - 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: 519.713375ms + - id: 0 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 118 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Client (Jan 25 18:42:54.501)","description":"This is just a test client.","organization_usage":"allow"} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: false + body: '{"name":"Test Client (Jan 25 18:42:54.501)","description":"This is just a test client.","client_id":"9kRK7ui7cDrnbAJQCjZCClClQoaCNpio","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"lifetime_in_seconds":36000},"sso_disabled":false,"cross_origin_auth":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 221.198375ms + - id: 1 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 239 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Resource Server (Jan 25 18:42:54.723)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 407 + uncompressed: false + body: '{"id":"63d16a1e67746e50f974b06b","name":"Test Resource Server (Jan 25 18:42:54.723)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 105.134458ms + - id: 2 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 115 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"client_id":"9kRK7ui7cDrnbAJQCjZCClClQoaCNpio","audience":"https://api.example.com/","scope":["create:resource"]} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 142 + uncompressed: false + body: '{"id":"cgr_24jRmQqGKUVtBy9g","client_id":"9kRK7ui7cDrnbAJQCjZCClClQoaCNpio","audience":"https://api.example.com/","scope":["create:resource"]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 114.195291ms + - id: 3 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 5 + transfer_encoding: [] + trailer: {} + host: go-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://go-auth0-dev.eu.auth0.com/api/v2/client-grants?include_totals=true&page=0&per_page=50 + method: GET + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: true + body: '{"total":6,"start":0,"limit":50,"client_grants":[{"id":"cgr_24jRmQqGKUVtBy9g","client_id":"9kRK7ui7cDrnbAJQCjZCClClQoaCNpio","audience":"https://api.example.com/","scope":["create:resource"]},{"id":"cgr_DrgPYSBkPAEFt6Yb","client_id":"Z3FKRhWMsXg7iwljDHcNtAkUnCRXYttO","audience":"https://go-auth0-dev.eu.auth0.com.eu.auth0.com/api/v2/","scope":[]},{"id":"cgr_EjTJshin5ruIvPqh","client_id":"3tjbn4dFI04fpHKnVlGs1GYDzQKIEmbF","audience":"https://go-auth0-dev.eu.auth0.com.eu.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations","read:organizations_summary","create:actions_log_sessions","create:authentication_methods","read:authentication_methods","update:authentication_methods","delete:authentication_methods"]},{"id":"cgr_F4BqCN0e5Grfa2Nj","client_id":"uRWKdiFmUEC3Kohfpq4HKjgKe26ynMSj","audience":"https://go-auth0-dev.eu.auth0.com.eu.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations_summary","create:actions_log_sessions","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations"]},{"id":"cgr_ZK11IyPr7cZLYwqC","client_id":"O6L9dP0GnD10qe4NVE6K67PiDEHxZEid","audience":"https://go-auth0-dev.eu.auth0.com.eu.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations"]},{"id":"cgr_r65kKhuS0nFMavVE","client_id":"8IgJbmEeGNsF7A4GXnYaiO6hScFYMjAv","audience":"https://go-auth0-dev.eu.auth0.com.eu.auth0.com/api/v2/","scope":["read:client_grants","create:client_grants","delete:client_grants","update:client_grants","read:users","update:users","delete:users","create:users","read:users_app_metadata","update:users_app_metadata","delete:users_app_metadata","create:users_app_metadata","read:user_custom_blocks","create:user_custom_blocks","delete:user_custom_blocks","create:user_tickets","read:clients","update:clients","delete:clients","create:clients","read:client_keys","update:client_keys","delete:client_keys","create:client_keys","read:connections","update:connections","delete:connections","create:connections","read:resource_servers","update:resource_servers","delete:resource_servers","create:resource_servers","read:device_credentials","update:device_credentials","delete:device_credentials","create:device_credentials","read:rules","update:rules","delete:rules","create:rules","read:rules_configs","update:rules_configs","delete:rules_configs","read:hooks","update:hooks","delete:hooks","create:hooks","read:actions","update:actions","delete:actions","create:actions","read:email_provider","update:email_provider","delete:email_provider","create:email_provider","blacklist:tokens","read:stats","read:insights","read:tenant_settings","update:tenant_settings","read:logs","read:logs_users","read:shields","create:shields","update:shields","delete:shields","read:anomaly_blocks","delete:anomaly_blocks","update:triggers","read:triggers","read:grants","delete:grants","read:guardian_factors","update:guardian_factors","read:guardian_enrollments","delete:guardian_enrollments","create:guardian_enrollment_tickets","read:user_idp_tokens","create:passwords_checking_job","delete:passwords_checking_job","read:custom_domains","delete:custom_domains","create:custom_domains","update:custom_domains","read:email_templates","create:email_templates","update:email_templates","read:mfa_policies","update:mfa_policies","read:roles","create:roles","delete:roles","update:roles","read:prompts","update:prompts","read:branding","update:branding","delete:branding","read:log_streams","create:log_streams","delete:log_streams","update:log_streams","create:signing_keys","read:signing_keys","update:signing_keys","read:limits","update:limits","create:role_members","read:role_members","delete:role_members","read:entitlements","read:attack_protection","update:attack_protection","read:organizations_summary","read:organizations","update:organizations","create:organizations","delete:organizations","create:organization_members","read:organization_members","delete:organization_members","create:organization_connections","read:organization_connections","update:organization_connections","delete:organization_connections","create:organization_member_roles","read:organization_member_roles","delete:organization_member_roles","create:organization_invitations","read:organization_invitations","delete:organization_invitations"]}]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 105.108083ms + - id: 4 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_24jRmQqGKUVtBy9g + 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: 6.187304542s + - id: 5 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/63d16a1e67746e50f974b06b + 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: 245.542917ms + - id: 6 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/9kRK7ui7cDrnbAJQCjZCClClQoaCNpio + 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: 162.026833ms \ No newline at end of file diff --git a/test/data/recordings/TestClientGrantManager_Update.yaml b/test/data/recordings/TestClientGrantManager_Update.yaml index b78176f0..228c407f 100644 --- a/test/data/recordings/TestClientGrantManager_Update.yaml +++ b/test/data/recordings/TestClientGrantManager_Update.yaml @@ -1,287 +1,252 @@ --- version: 2 interactions: - - id: 0 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 1125 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Client (Aug 13 15:34:22.574)","description":"This is just a test client.","jwt_configuration":{"alg":"RS256"},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"name":"Test Credential (Aug 13 15:34:22.574)","credential_type":"public_key","pem":"-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAua6LXMfgDE/tDdkOL1Oe\n3oWUwg1r4dSTg9L7RCcI5hItUzmkVofHtWN0H4CH2lm2ANmaJUsnhzctYowYW2+R\ntHvU9afTmtbdhpy993972hUqZSYLsE3iGziphYkOKVsqq38+VRH3TNg93zSLoRao\nJnTTkMXseVqiyqYRmFN8+gQQoEclHSGPUWQG5XMZ+hhuXeFyo+Yw/qbZWca/6/2I\n3rsca9jXR1alhxhHrXrg8N4Dm3gBgGbmiht6YYYT2Tyl1OqB9+iOI/9D7dfoCF6X\nAWJXRE454cmC8k8oucpjZVpflA+ocKshwPDR6YTLQYbXYiaWxEoaz0QGUErNQBnG\nI+sr9jDY3ua/s6HF6h0qyi/HVZH4wx+m4CtOfJoYTjrGBbaRszzUxhtSN2/MhXDu\n+a35q9/2zcu/3fjkkfVvGUt+NyyiYOKQ9vsJC1g/xxdUWtowjNwjfZE2zcG4usi8\nr38Bp0lmiipAsMLduZM/D5dFXkRdWCBNDfULmmg/4nv2wwjbjQuLemAMh7mmrztW\ni/85WMnjKQZT8NqS43pmgyIzg1gK1neMqdS90YmQ/PvJ36qALxCs245w1JpN9BAL\nJbwxCg/dbmKT7PalfWrksx9hGcJxtGqebldaOpw+5GVIPxxtC1C0gVr9BKeiDS3f\naibASY5pIRiKENmbZELDtucCAwEAAQ==\n-----END PUBLIC KEY-----"}]}}} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: false - body: '{"name":"Test Client (Aug 13 15:34:22.574)","description":"This is just a test client.","client_id":"ar2x5r3qWcqgmnWN76KhjjK64CZ7gcD1","client_secret":"[REDACTED]","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"alg":"RS256"},"signing_keys":[{"cert":"[REDACTED]"}],"sso_disabled":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"id":"cred_98sVridhKNcEujTNqEtEm7","name":"Test Credential (Aug 13 15:34:22.574)","kid":"4e7yYf0TKdyTLbVnpq2wLN6mZ8t7eb9UJkMksyHj9iU","credential_type":"public_key","alg":"RS256","created_at":"2024-08-13T10:04:22.824Z","updated_at":"2024-08-13T10:04:22.824Z"}]}}}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 499.039833ms - - id: 1 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 382 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"name":"Test Resource Server (Aug 13 15:34:23.074)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600,"enforce_policies":false,"token_dialect":"access_token"} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 550 - uncompressed: false - body: '{"id":"66bb2fa7d05205007d0846cf","name":"Test Resource Server (Aug 13 15:34:23.074)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false,"enforce_policies":false,"token_dialect":"access_token"}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 408.47175ms - - id: 2 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers?identifiers=https%3A%2F%2Fapi.example.com%2F&include_totals=true&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"total":1,"start":0,"limit":50,"resource_servers":[{"id":"66bb2fa7d05205007d0846cf","name":"Test Resource Server (Aug 13 15:34:23.074)","identifier":"https://api.example.com/","allow_offline_access":false,"skip_consent_for_verifiable_first_party_clients":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"signing_alg":"HS256","signing_secret":"mYVAyb11UTMwauYk0LWy3KmT2fHUGJTw","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"enforce_policies":false,"token_dialect":"access_token"}]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 382.358ms - - id: 3 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 115 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"client_id":"ar2x5r3qWcqgmnWN76KhjjK64CZ7gcD1","audience":"https://api.example.com/","scope":["create:resource"]} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants - method: POST - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: 142 - uncompressed: false - body: '{"id":"cgr_wWa4LQeIEiWZRhUz","client_id":"ar2x5r3qWcqgmnWN76KhjjK64CZ7gcD1","audience":"https://api.example.com/","scope":["create:resource"]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 201 Created - code: 201 - duration: 327.424292ms - - id: 4 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 48 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: | - {"scope":["create:resource","update:resource"]} - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_wWa4LQeIEiWZRhUz - method: PATCH - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"id":"cgr_wWa4LQeIEiWZRhUz","client_id":"ar2x5r3qWcqgmnWN76KhjjK64CZ7gcD1","audience":"https://api.example.com/","scope":["create:resource","update:resource"]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 355.270583ms - - id: 5 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_wWa4LQeIEiWZRhUz - 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: 364.026208ms - - id: 6 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/66bb2fa7d05205007d0846cf - 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: 599.73425ms - - id: 7 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/ar2x5r3qWcqgmnWN76KhjjK64CZ7gcD1 - 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: 365.04925ms + - id: 0 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 118 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Client (Jan 25 18:43:01.653)","description":"This is just a test client.","organization_usage":"allow"} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: false + body: '{"name":"Test Client (Jan 25 18:43:01.653)","description":"This is just a test client.","client_id":"SvStOMA7tiUjzAIytYFlTYnyJTlI1ovm","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"lifetime_in_seconds":36000},"sso_disabled":false,"cross_origin_auth":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow"}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 392.490833ms + - id: 1 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 239 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"name":"Test Resource Server (Jan 25 18:43:02.046)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 407 + uncompressed: false + body: '{"id":"63d16a26f2a5bdbc6364494b","name":"Test Resource Server (Jan 25 18:43:02.046)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 132.099125ms + - id: 2 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 115 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"client_id":"SvStOMA7tiUjzAIytYFlTYnyJTlI1ovm","audience":"https://api.example.com/","scope":["create:resource"]} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants + method: POST + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: 142 + uncompressed: false + body: '{"id":"cgr_h1uMVCW4nYELv34v","client_id":"SvStOMA7tiUjzAIytYFlTYnyJTlI1ovm","audience":"https://api.example.com/","scope":["create:resource"]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 201 Created + code: 201 + duration: 109.121667ms + - id: 3 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 48 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: | + {"scope":["create:resource","update:resource"]} + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_h1uMVCW4nYELv34v + method: PATCH + response: + proto: HTTP/2.0 + proto_major: 2 + proto_minor: 0 + transfer_encoding: [] + trailer: {} + content_length: -1 + uncompressed: true + body: '{"id":"cgr_h1uMVCW4nYELv34v","client_id":"SvStOMA7tiUjzAIytYFlTYnyJTlI1ovm","audience":"https://api.example.com/","scope":["create:resource","update:resource"]}' + headers: + Content-Type: + - application/json; charset=utf-8 + status: 200 OK + code: 200 + duration: 96.772625ms + - id: 4 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_h1uMVCW4nYELv34v + 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: 87.473333ms + - id: 5 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/63d16a26f2a5bdbc6364494b + 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: 232.015166ms + - id: 6 + request: + proto: HTTP/1.1 + proto_major: 1 + proto_minor: 1 + content_length: 0 + transfer_encoding: [] + trailer: {} + host: go-auth0-dev.eu.auth0.com + remote_addr: "" + request_uri: "" + body: "" + form: {} + headers: + Content-Type: + - application/json + User-Agent: + - Go-Auth0-SDK/latest + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/SvStOMA7tiUjzAIytYFlTYnyJTlI1ovm + 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: 118.23375ms \ No newline at end of file diff --git a/test/data/recordings/TestOrganizationManager_ClientGrantsWithOrg.yaml b/test/data/recordings/TestOrganizationManager_ClientGrantsWithOrg.yaml index 1b8a7771..71836716 100644 --- a/test/data/recordings/TestOrganizationManager_ClientGrantsWithOrg.yaml +++ b/test/data/recordings/TestOrganizationManager_ClientGrantsWithOrg.yaml @@ -13,7 +13,7 @@ interactions: remote_addr: "" request_uri: "" body: | - {"name":"test-organization661","display_name":"Test Organization","branding":{"logo_url":"https://example.com/logo.gif"}} + {"name":"test-organization727","display_name":"Test Organization","branding":{"logo_url":"https://example.com/logo.gif"}} form: {} headers: Content-Type: @@ -30,13 +30,13 @@ interactions: trailer: {} content_length: 149 uncompressed: false - body: '{"branding":{"logo_url":"https://example.com/logo.gif"},"id":"org_CEWq384R0LY0Zvii","display_name":"Test Organization","name":"test-organization661"}' + body: '{"branding":{"logo_url":"https://example.com/logo.gif"},"id":"org_lggcUnngbrUnOdzL","display_name":"Test Organization","name":"test-organization727"}' headers: Content-Type: - application/json; charset=utf-8 status: 201 Created code: 201 - duration: 1.088426875s + duration: 1.149214667s - id: 1 request: proto: HTTP/1.1 @@ -49,7 +49,7 @@ interactions: remote_addr: "" request_uri: "" body: | - {"name":"Test Resource Server (Aug 13 15:07:30.395)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600,"enforce_policies":false,"token_dialect":"access_token"} + {"name":"Test Resource Server (Aug 16 11:33:14.973)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600,"enforce_policies":false,"token_dialect":"access_token"} form: {} headers: Content-Type: @@ -66,61 +66,26 @@ interactions: trailer: {} content_length: 550 uncompressed: false - body: '{"id":"66bb295aa5e5fdad3d1c8a14","name":"Test Resource Server (Aug 13 15:07:30.395)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false,"enforce_policies":false,"token_dialect":"access_token"}' + body: '{"id":"66beeba3f6883b19383ca227","name":"Test Resource Server (Aug 16 11:33:14.973)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false,"enforce_policies":false,"token_dialect":"access_token"}' headers: Content-Type: - application/json; charset=utf-8 status: 201 Created code: 201 - duration: 455.006166ms + duration: 365.995959ms - id: 2 request: proto: HTTP/1.1 proto_major: 1 proto_minor: 1 - content_length: 0 - transfer_encoding: [] - trailer: {} - host: go-auth0-dev.eu.auth0.com - remote_addr: "" - request_uri: "" - body: "" - form: {} - headers: - Content-Type: - - application/json - User-Agent: - - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers?identifiers=https%3A%2F%2Fapi.example.com%2F&include_totals=true&per_page=50 - method: GET - response: - proto: HTTP/2.0 - proto_major: 2 - proto_minor: 0 - transfer_encoding: [] - trailer: {} - content_length: -1 - uncompressed: true - body: '{"total":1,"start":0,"limit":50,"resource_servers":[{"id":"66bb295aa5e5fdad3d1c8a14","name":"Test Resource Server (Aug 13 15:07:30.395)","identifier":"https://api.example.com/","allow_offline_access":false,"skip_consent_for_verifiable_first_party_clients":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"signing_alg":"HS256","signing_secret":"Eb2CxioxzQDc0izUf8hGtFxtoNcBFQDO","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"enforce_policies":false,"token_dialect":"access_token"}]}' - headers: - Content-Type: - - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 361.909875ms - - id: 3 - request: - proto: HTTP/1.1 - proto_major: 1 - proto_minor: 1 - content_length: 1125 + content_length: 215 transfer_encoding: [] trailer: {} host: go-auth0-dev.eu.auth0.com remote_addr: "" request_uri: "" body: | - {"name":"Test Client (Aug 13 15:07:31.214)","description":"This is just a test client.","jwt_configuration":{"alg":"RS256"},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"name":"Test Credential (Aug 13 15:07:31.214)","credential_type":"public_key","pem":"-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAua6LXMfgDE/tDdkOL1Oe\n3oWUwg1r4dSTg9L7RCcI5hItUzmkVofHtWN0H4CH2lm2ANmaJUsnhzctYowYW2+R\ntHvU9afTmtbdhpy993972hUqZSYLsE3iGziphYkOKVsqq38+VRH3TNg93zSLoRao\nJnTTkMXseVqiyqYRmFN8+gQQoEclHSGPUWQG5XMZ+hhuXeFyo+Yw/qbZWca/6/2I\n3rsca9jXR1alhxhHrXrg8N4Dm3gBgGbmiht6YYYT2Tyl1OqB9+iOI/9D7dfoCF6X\nAWJXRE454cmC8k8oucpjZVpflA+ocKshwPDR6YTLQYbXYiaWxEoaz0QGUErNQBnG\nI+sr9jDY3ua/s6HF6h0qyi/HVZH4wx+m4CtOfJoYTjrGBbaRszzUxhtSN2/MhXDu\n+a35q9/2zcu/3fjkkfVvGUt+NyyiYOKQ9vsJC1g/xxdUWtowjNwjfZE2zcG4usi8\nr38Bp0lmiipAsMLduZM/D5dFXkRdWCBNDfULmmg/4nv2wwjbjQuLemAMh7mmrztW\ni/85WMnjKQZT8NqS43pmgyIzg1gK1neMqdS90YmQ/PvJ36qALxCs245w1JpN9BAL\nJbwxCg/dbmKT7PalfWrksx9hGcJxtGqebldaOpw+5GVIPxxtC1C0gVr9BKeiDS3f\naibASY5pIRiKENmbZELDtucCAwEAAQ==\n-----END PUBLIC KEY-----"}]}}} + {"name":"Test Client (Aug 16 11:33:15.340)","description":"This is just a test client.","organization_usage":"allow","default_organization":{"flows":["client_credentials"],"organization_id":"org_lggcUnngbrUnOdzL"}} form: {} headers: Content-Type: @@ -137,14 +102,14 @@ interactions: trailer: {} content_length: -1 uncompressed: false - body: '{"name":"Test Client (Aug 13 15:07:31.214)","description":"This is just a test client.","client_id":"q5ZqaoojuNDAB70pjG5i6gvAIKyhWn0E","client_secret":"[REDACTED]","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"alg":"RS256"},"signing_keys":[{"cert":"[REDACTED]"}],"sso_disabled":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow","client_authentication_methods":{"private_key_jwt":{"credentials":[{"id":"cred_2TegX5JGH3xvru32HB5ngJ","name":"Test Credential (Aug 13 15:07:31.214)","kid":"4e7yYf0TKdyTLbVnpq2wLN6mZ8t7eb9UJkMksyHj9iU","credential_type":"public_key","alg":"RS256","created_at":"2024-08-13T09:37:31.526Z","updated_at":"2024-08-13T09:37:31.526Z"}]}}}' + body: '{"name":"Test Client (Aug 16 11:33:15.340)","description":"This is just a test client.","client_id":"wKAZQvmHThL24INsAhN5GOWEaJpVNohn","client_secret":"[REDACTED]","is_first_party":true,"is_token_endpoint_ip_header_trusted":false,"oidc_conformant":false,"jwt_configuration":{"secret_encoded":false,"lifetime_in_seconds":36000},"signing_keys":[{"cert":"[REDACTED]"}],"sso_disabled":false,"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true,"refresh_token":{"rotation_type":"non-rotating","expiration_type":"non-expiring","leeway":0,"token_lifetime":2592000,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"idle_token_lifetime":1296000},"organization_usage":"allow","default_organization":{"flows":["client_credentials"],"organization_id":"org_lggcUnngbrUnOdzL"}}' headers: Content-Type: - application/json; charset=utf-8 status: 201 Created code: 201 - duration: 528.532917ms - - id: 4 + duration: 559.516542ms + - id: 3 request: proto: HTTP/1.1 proto_major: 1 @@ -156,7 +121,7 @@ interactions: remote_addr: "" request_uri: "" body: | - {"client_id":"q5ZqaoojuNDAB70pjG5i6gvAIKyhWn0E","audience":"https://api.example.com/","scope":["create:resource","create:organization_client_grants"],"allow_any_organization":true,"organization_usage":"allow"} + {"client_id":"wKAZQvmHThL24INsAhN5GOWEaJpVNohn","audience":"https://api.example.com/","scope":["create:resource","create:organization_client_grants"],"allow_any_organization":true,"organization_usage":"allow"} form: {} headers: Content-Type: @@ -173,14 +138,14 @@ interactions: trailer: {} content_length: 237 uncompressed: false - body: '{"id":"cgr_x2n6rKG6fubYgW5y","client_id":"q5ZqaoojuNDAB70pjG5i6gvAIKyhWn0E","audience":"https://api.example.com/","scope":["create:resource","create:organization_client_grants"],"organization_usage":"allow","allow_any_organization":true}' + body: '{"id":"cgr_RGwcHWvSNbHtjv1J","client_id":"wKAZQvmHThL24INsAhN5GOWEaJpVNohn","audience":"https://api.example.com/","scope":["create:resource","create:organization_client_grants"],"organization_usage":"allow","allow_any_organization":true}' headers: Content-Type: - application/json; charset=utf-8 status: 201 Created code: 201 - duration: 341.373375ms - - id: 5 + duration: 344.337666ms + - id: 4 request: proto: HTTP/1.1 proto_major: 1 @@ -192,14 +157,14 @@ interactions: remote_addr: "" request_uri: "" body: | - {"grant_id":"cgr_x2n6rKG6fubYgW5y"} + {"grant_id":"cgr_RGwcHWvSNbHtjv1J"} form: {} headers: Content-Type: - application/json User-Agent: - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_CEWq384R0LY0Zvii/client-grants + url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_lggcUnngbrUnOdzL/client-grants method: POST response: proto: HTTP/2.0 @@ -209,14 +174,14 @@ interactions: trailer: {} content_length: 184 uncompressed: false - body: '{"grant_id":"cgr_x2n6rKG6fubYgW5y","client_id":"q5ZqaoojuNDAB70pjG5i6gvAIKyhWn0E","audience":"https://api.example.com/","scope":["create:resource","create:organization_client_grants"]}' + body: '{"grant_id":"cgr_RGwcHWvSNbHtjv1J","client_id":"wKAZQvmHThL24INsAhN5GOWEaJpVNohn","audience":"https://api.example.com/","scope":["create:resource","create:organization_client_grants"]}' headers: Content-Type: - application/json; charset=utf-8 status: 201 Created code: 201 - duration: 455.857875ms - - id: 6 + duration: 402.870333ms + - id: 5 request: proto: HTTP/1.1 proto_major: 1 @@ -234,7 +199,7 @@ interactions: - application/json User-Agent: - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_CEWq384R0LY0Zvii/client-grants?grant_ids=cgr_x2n6rKG6fubYgW5y&include_totals=true&per_page=50 + url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_lggcUnngbrUnOdzL/client-grants?grant_ids=cgr_RGwcHWvSNbHtjv1J&include_totals=true&per_page=50 method: GET response: proto: HTTP/2.0 @@ -244,14 +209,14 @@ interactions: trailer: {} content_length: -1 uncompressed: true - body: '{"client_grants":[{"id":"cgr_x2n6rKG6fubYgW5y","client_id":"q5ZqaoojuNDAB70pjG5i6gvAIKyhWn0E","audience":"https://api.example.com/","scope":["create:resource","create:organization_client_grants"],"organization_usage":"allow","allow_any_organization":true}],"start":0,"limit":50,"total":1}' + body: '{"client_grants":[{"id":"cgr_RGwcHWvSNbHtjv1J","client_id":"wKAZQvmHThL24INsAhN5GOWEaJpVNohn","audience":"https://api.example.com/","scope":["create:resource","create:organization_client_grants"],"organization_usage":"allow","allow_any_organization":true}],"start":0,"limit":50,"total":1}' headers: Content-Type: - application/json; charset=utf-8 status: 200 OK code: 200 - duration: 360.171ms - - id: 7 + duration: 413.115417ms + - id: 6 request: proto: HTTP/1.1 proto_major: 1 @@ -269,24 +234,24 @@ interactions: - application/json User-Agent: - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_CEWq384R0LY0Zvii/client-grants/cgr_x2n6rKG6fubYgW5y - method: DELETE + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients?include_totals=true&per_page=50&q=client_grant.organization_id%3Aorg_lggcUnngbrUnOdzL + method: GET response: proto: HTTP/2.0 proto_major: 2 proto_minor: 0 transfer_encoding: [] trailer: {} - content_length: 0 - uncompressed: false - body: "" + content_length: -1 + uncompressed: true + body: '{"total":1,"start":0,"limit":50,"clients":[{"tenant":"go-auth0-dev.eu.auth0.com","global":false,"is_token_endpoint_ip_header_trusted":false,"name":"Test Client (Aug 16 11:33:15.340)","description":"This is just a test client.","organization_usage":"allow","default_organization":{"flows":["client_credentials"],"organization_id":"org_lggcUnngbrUnOdzL"},"is_first_party":true,"sso_disabled":false,"cross_origin_auth":false,"oidc_conformant":false,"refresh_token":{"expiration_type":"non-expiring","leeway":0,"infinite_token_lifetime":true,"infinite_idle_token_lifetime":true,"token_lifetime":2592000,"idle_token_lifetime":1296000,"rotation_type":"non-rotating"},"signing_keys":[{"cert":"-----BEGIN CERTIFICATE-----\r\nMIIDTTCCAjWgAwIBAgIJezpPPUrti4p8MA0GCSqGSIb3DQEBCwUAMEQxQjBABgNV\r\nBAMTOXdpdHR5LXNpbHZlci1zYWlsZmlzaC1zdXMxLXN0YWdpbmctMjAyNDA3MDQu\r\nc3VzLmF1dGgwLmNvbTAeFw0yNDA3MDQxMzM3MzVaFw0zODAzMTMxMzM3MzVaMEQx\r\nQjBABgNVBAMTOXdpdHR5LXNpbHZlci1zYWlsZmlzaC1zdXMxLXN0YWdpbmctMjAy\r\nNDA3MDQuc3VzLmF1dGgwLmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoC\r\nggEBAL6GMpexnHdM7bDiuusAo6wzLhVK+3MIpookQ+1+2zLNffSLqDbwV26Vd/8o\r\nyofd6J880A32BdoQ1tYpnr8Uly6qZK0Qe4tf/s+N6pttXiFIYL1XXR65DuNAIon/\r\nHkjGNthVPAkLnr6HgfWqALzLA2zkS2BkobmubkxT17gbvrsFfGKQBkcCULJKj2S5\r\nD+pyZSCt4fQeleTdz6j1RLLWQvl+/YqbJGGCDM95q28vPRaW3Rl/qUaIa6QY0X8y\r\nfU6HQ7E+jvuYJZ/E5EMS+Hw8+eZQQfiSs99F+GQqeDGeXtJsupiLUEHO40LgtkuE\r\nFzTa68n9/odOeAKHWCgsr4EdbMECAwEAAaNCMEAwDwYDVR0TAQH/BAUwAwEB/zAd\r\nBgNVHQ4EFgQUTEp+zPt7/ZUz2Aoym7fHUXxs5wMwDgYDVR0PAQH/BAQDAgKEMA0G\r\nCSqGSIb3DQEBCwUAA4IBAQC26E1HD+IXgPFgsiSpCIt5A9G8UHSk7EOeTG7cKytm\r\ntKco5PqavOwngluBvu2aKZAZTJEi3yW4etWxFTO/axrY9L3A0SDr/26ZVRn8o+np\r\nEOW+0nGpZR9giLzSK5zObJwp6O3tLIqBLyJ0OrijQolM9PYAOhEXE0y1qyJhWEAs\r\n3RrtV4qU4oMtVyCDMOHx87/IWBEUeCjpJOkOfFopylVAdVh1W7sl1YK5A/ti9Usr\r\nl4jSJnHMFaFvMZLIVvctK6FtRQJp8HNkJsCCc5TDBMxCtT3tqxwZkTWh/ukMQPY9\r\nlt9ON+Vyyxrg8QeV5UA3bff2b4KW1+NM14v4sFhvCcDV\r\n-----END CERTIFICATE-----","pkcs7":"-----BEGIN PKCS7-----\r\nMIIDfAYJKoZIhvcNAQcCoIIDbTCCA2kCAQExADALBgkqhkiG9w0BBwGgggNRMIID\r\nTTCCAjWgAwIBAgIJezpPPUrti4p8MA0GCSqGSIb3DQEBCwUAMEQxQjBABgNVBAMT\r\nOXdpdHR5LXNpbHZlci1zYWlsZmlzaC1zdXMxLXN0YWdpbmctMjAyNDA3MDQuc3Vz\r\nLmF1dGgwLmNvbTAeFw0yNDA3MDQxMzM3MzVaFw0zODAzMTMxMzM3MzVaMEQxQjBA\r\nBgNVBAMTOXdpdHR5LXNpbHZlci1zYWlsZmlzaC1zdXMxLXN0YWdpbmctMjAyNDA3\r\nMDQuc3VzLmF1dGgwLmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB\r\nAL6GMpexnHdM7bDiuusAo6wzLhVK+3MIpookQ+1+2zLNffSLqDbwV26Vd/8oyofd\r\n6J880A32BdoQ1tYpnr8Uly6qZK0Qe4tf/s+N6pttXiFIYL1XXR65DuNAIon/HkjG\r\nNthVPAkLnr6HgfWqALzLA2zkS2BkobmubkxT17gbvrsFfGKQBkcCULJKj2S5D+py\r\nZSCt4fQeleTdz6j1RLLWQvl+/YqbJGGCDM95q28vPRaW3Rl/qUaIa6QY0X8yfU6H\r\nQ7E+jvuYJZ/E5EMS+Hw8+eZQQfiSs99F+GQqeDGeXtJsupiLUEHO40LgtkuEFzTa\r\n68n9/odOeAKHWCgsr4EdbMECAwEAAaNCMEAwDwYDVR0TAQH/BAUwAwEB/zAdBgNV\r\nHQ4EFgQUTEp+zPt7/ZUz2Aoym7fHUXxs5wMwDgYDVR0PAQH/BAQDAgKEMA0GCSqG\r\nSIb3DQEBCwUAA4IBAQC26E1HD+IXgPFgsiSpCIt5A9G8UHSk7EOeTG7cKytmtKco\r\n5PqavOwngluBvu2aKZAZTJEi3yW4etWxFTO/axrY9L3A0SDr/26ZVRn8o+npEOW+\r\n0nGpZR9giLzSK5zObJwp6O3tLIqBLyJ0OrijQolM9PYAOhEXE0y1qyJhWEAs3Rrt\r\nV4qU4oMtVyCDMOHx87/IWBEUeCjpJOkOfFopylVAdVh1W7sl1YK5A/ti9Usrl4jS\r\nJnHMFaFvMZLIVvctK6FtRQJp8HNkJsCCc5TDBMxCtT3tqxwZkTWh/ukMQPY9lt9O\r\nN+Vyyxrg8QeV5UA3bff2b4KW1+NM14v4sFhvCcDVMQA=\r\n-----END PKCS7-----\r\n","subject":"deprecated"}],"client_id":"wKAZQvmHThL24INsAhN5GOWEaJpVNohn","callback_url_template":false,"client_secret":"wTDl95C8e6IYwiAbrYHq00hSPB33tuaCK9v09porlQA9nZBRDrABcQwhUPyJoSaM","jwt_configuration":{"lifetime_in_seconds":36000,"secret_encoded":false},"grant_types":["authorization_code","implicit","refresh_token","client_credentials"],"custom_login_page_on":true}]}' headers: Content-Type: - application/json; charset=utf-8 - status: 204 No Content - code: 204 - duration: 401.86725ms - - id: 8 + status: 200 OK + code: 200 + duration: 363.315875ms + - id: 7 request: proto: HTTP/1.1 proto_major: 1 @@ -304,24 +269,24 @@ interactions: - application/json User-Agent: - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_CEWq384R0LY0Zvii/client-grants?include_totals=true&per_page=50 - method: GET + url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_lggcUnngbrUnOdzL/client-grants/cgr_RGwcHWvSNbHtjv1J + method: DELETE response: proto: HTTP/2.0 proto_major: 2 proto_minor: 0 transfer_encoding: [] trailer: {} - content_length: -1 - uncompressed: true - body: '{"client_grants":[],"start":0,"limit":50,"total":0}' + content_length: 0 + uncompressed: false + body: "" headers: Content-Type: - application/json; charset=utf-8 - status: 200 OK - code: 200 - duration: 352.621875ms - - id: 9 + status: 204 No Content + code: 204 + duration: 341.365708ms + - id: 8 request: proto: HTTP/1.1 proto_major: 1 @@ -339,7 +304,7 @@ interactions: - application/json User-Agent: - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_x2n6rKG6fubYgW5y + url: https://go-auth0-dev.eu.auth0.com/api/v2/client-grants/cgr_RGwcHWvSNbHtjv1J method: DELETE response: proto: HTTP/2.0 @@ -355,8 +320,8 @@ interactions: - application/json; charset=utf-8 status: 204 No Content code: 204 - duration: 624.52075ms - - id: 10 + duration: 397.785583ms + - id: 9 request: proto: HTTP/1.1 proto_major: 1 @@ -374,7 +339,7 @@ interactions: - application/json User-Agent: - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/q5ZqaoojuNDAB70pjG5i6gvAIKyhWn0E + url: https://go-auth0-dev.eu.auth0.com/api/v2/clients/wKAZQvmHThL24INsAhN5GOWEaJpVNohn method: DELETE response: proto: HTTP/2.0 @@ -390,8 +355,8 @@ interactions: - application/json; charset=utf-8 status: 204 No Content code: 204 - duration: 413.712959ms - - id: 11 + duration: 620.146625ms + - id: 10 request: proto: HTTP/1.1 proto_major: 1 @@ -409,7 +374,7 @@ interactions: - application/json User-Agent: - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/66bb295aa5e5fdad3d1c8a14 + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/66beeba3f6883b19383ca227 method: DELETE response: proto: HTTP/2.0 @@ -425,8 +390,8 @@ interactions: - application/json; charset=utf-8 status: 204 No Content code: 204 - duration: 395.256ms - - id: 12 + duration: 387.508542ms + - id: 11 request: proto: HTTP/1.1 proto_major: 1 @@ -444,7 +409,7 @@ interactions: - application/json User-Agent: - Go-Auth0/1.8.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_CEWq384R0LY0Zvii + url: https://go-auth0-dev.eu.auth0.com/api/v2/organizations/org_lggcUnngbrUnOdzL method: DELETE response: proto: HTTP/2.0 @@ -460,4 +425,4 @@ interactions: - application/json; charset=utf-8 status: 204 No Content code: 204 - duration: 332.6825ms + duration: 546.893459ms diff --git a/test/data/recordings/TestResourceServer_List.yaml b/test/data/recordings/TestResourceServer_List.yaml index 181dfa98..482d70c1 100644 --- a/test/data/recordings/TestResourceServer_List.yaml +++ b/test/data/recordings/TestResourceServer_List.yaml @@ -6,20 +6,20 @@ interactions: proto: HTTP/1.1 proto_major: 1 proto_minor: 1 - content_length: 295 + content_length: 382 transfer_encoding: [] trailer: {} host: go-auth0-dev.eu.auth0.com remote_addr: "" request_uri: "" body: | - {"name":"Test Resource Server (Jun 11 18:23:35.454)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600,"enforce_policies":false,"token_dialect":"access_token"} + {"name":"Test Resource Server (Aug 16 11:26:20.586)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","token_lifetime":7200,"token_lifetime_for_web":3600,"enforce_policies":false,"token_dialect":"access_token"} form: {} headers: Content-Type: - application/json User-Agent: - - Go-Auth0/1.6.0 + - Go-Auth0/1.8.0 url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers method: POST response: @@ -28,15 +28,15 @@ interactions: proto_minor: 0 transfer_encoding: [] trailer: {} - content_length: 463 + content_length: 550 uncompressed: false - body: '{"id":"666848cf684d1a66674afe63","name":"Test Resource Server (Jun 11 18:23:35.454)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false,"enforce_policies":false,"token_dialect":"access_token"}' + body: '{"id":"66beea0549c0082877188f06","name":"Test Resource Server (Aug 16 11:26:20.586)","identifier":"https://api.example.com/","scopes":[{"value":"create:resource","description":"Create Resource"},{"value":"create:organization_client_grants","description":"Create Org Client Grants"}],"signing_alg":"HS256","allow_offline_access":false,"token_lifetime":7200,"token_lifetime_for_web":3600,"skip_consent_for_verifiable_first_party_clients":false,"enforce_policies":false,"token_dialect":"access_token"}' headers: Content-Type: - application/json; charset=utf-8 status: 201 Created code: 201 - duration: 334.320334ms + duration: 1.115222584s - id: 1 request: proto: HTTP/1.1 @@ -54,8 +54,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0/1.6.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers?fields=id&include_fields=true&include_totals=true&per_page=50 + - Go-Auth0/1.8.0 + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers?fields=id%2Cidentifier&identifiers=https%3A%2F%2Fapi.example.com%2F&include_fields=true&include_totals=true&per_page=50 method: GET response: proto: HTTP/2.0 @@ -65,13 +65,13 @@ interactions: trailer: {} content_length: -1 uncompressed: true - body: '{"total":7,"start":0,"limit":50,"resource_servers":[{"id":"660bf8bc2cd7cc0b5b37194c"},{"id":"663239ff1471431febe3405b"},{"id":"66323a001417972c4a002dae"},{"id":"664f1ad673f9ef17a7933a35"},{"id":"664f1ad61f3095fe8063e6d0"},{"id":"6650614512e3459425c972ff"},{"id":"666848cf684d1a66674afe63"}]}' + body: '{"total":1,"start":0,"limit":50,"resource_servers":[{"id":"66beea0549c0082877188f06","identifier":"https://api.example.com/"}]}' headers: Content-Type: - application/json; charset=utf-8 status: 200 OK code: 200 - duration: 379.520334ms + duration: 496.084042ms - id: 2 request: proto: HTTP/1.1 @@ -89,8 +89,8 @@ interactions: Content-Type: - application/json User-Agent: - - Go-Auth0/1.6.0 - url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/666848cf684d1a66674afe63 + - Go-Auth0/1.8.0 + url: https://go-auth0-dev.eu.auth0.com/api/v2/resource-servers/66beea0549c0082877188f06 method: DELETE response: proto: HTTP/2.0 @@ -106,4 +106,4 @@ interactions: - application/json; charset=utf-8 status: 204 No Content code: 204 - duration: 320.687542ms + duration: 496.653875ms