diff --git a/corporate/urls.py b/corporate/urls.py index 1acc3d713f..85101e58bc 100644 --- a/corporate/urls.py +++ b/corporate/urls.py @@ -31,8 +31,8 @@ from corporate.views.portico import ( ) from corporate.views.remote_billing_page import ( remote_billing_legacy_server_login, + remote_realm_billing_finalize_login, remote_realm_plans_page, - remote_server_billing_finalize_login, remote_server_plans_page, ) from corporate.views.session import ( @@ -183,9 +183,7 @@ i18n_urlpatterns += landing_page_urls urlpatterns = list(i18n_urlpatterns) urlpatterns += [ - path( - "remote-billing-login//", remote_server_billing_finalize_login - ), + path("remote-billing-login/", remote_realm_billing_finalize_login), # Remote server billing endpoints. path("realm//plans/", remote_realm_plans_page, name="remote_realm_plans_page"), path( diff --git a/corporate/views/remote_billing_page.py b/corporate/views/remote_billing_page.py index c36c5a20ec..0cbc027e2a 100644 --- a/corporate/views/remote_billing_page.py +++ b/corporate/views/remote_billing_page.py @@ -41,7 +41,7 @@ VALID_NEXT_PAGES_TYPE = Literal[None, "sponsorship", "upgrade", "billing", "plan @csrf_exempt @typed_endpoint -def remote_server_billing_entry( +def remote_realm_billing_entry( request: HttpRequest, remote_server: RemoteZulipServer, *, @@ -75,13 +75,13 @@ def remote_server_billing_entry( billing_access_url = ( f"{settings.EXTERNAL_URI_SCHEME}{settings.SELF_HOSTING_MANAGEMENT_SUBDOMAIN}.{settings.EXTERNAL_HOST}" - + reverse(remote_server_billing_finalize_login, args=[signed_identity_dict]) + + reverse(remote_realm_billing_finalize_login, args=[signed_identity_dict]) ) return json_success(request, data={"billing_access_url": billing_access_url}) @self_hosting_management_endpoint -def remote_server_billing_finalize_login( +def remote_realm_billing_finalize_login( request: HttpRequest, signed_billing_access_token: str, ) -> HttpResponse: diff --git a/zilencer/urls.py b/zilencer/urls.py index 0b70d7a17b..d2dfa72eb8 100644 --- a/zilencer/urls.py +++ b/zilencer/urls.py @@ -3,7 +3,7 @@ from typing import Any from django.conf.urls import include from django.urls import path -from corporate.views.remote_billing_page import remote_server_billing_entry +from corporate.views.remote_billing_page import remote_realm_billing_entry from zilencer.auth import remote_server_path from zilencer.views import ( deactivate_remote_server, @@ -34,7 +34,7 @@ push_bouncer_patterns = [ remote_server_path("remotes/server/analytics/status", GET=remote_server_check_analytics), ] -billing_patterns = [remote_server_path("remotes/server/billing", POST=remote_server_billing_entry)] +billing_patterns = [remote_server_path("remotes/server/billing", POST=remote_realm_billing_entry)] urlpatterns = [ path("api/v1/", include(push_bouncer_patterns)),