diff --git a/backend/internal/service/openai_gateway_grok.go b/backend/internal/service/openai_gateway_grok.go index 87899c1350..4d367c9aeb 100644 --- a/backend/internal/service/openai_gateway_grok.go +++ b/backend/internal/service/openai_gateway_grok.go @@ -1370,8 +1370,6 @@ func (s *OpenAIGatewayService) handleGrokAccountUpstreamError(ctx context.Contex s.tempUnscheduleGrok(ctx, account, 30*time.Minute, "grok payment required") case http.StatusForbidden: s.tempUnscheduleGrok(ctx, account, 30*time.Minute, "grok access or entitlement denied") - case http.StatusMethodNotAllowed: - s.tempUnscheduleGrok(ctx, account, 30*time.Minute, "grok endpoint not supported (405)") case http.StatusTooManyRequests: // updateGrokUsageSnapshot installs rate-limit state for non-pool accounts. default: diff --git a/backend/internal/service/openai_gateway_grok_test.go b/backend/internal/service/openai_gateway_grok_test.go index 30c25ba586..19942eae7d 100644 --- a/backend/internal/service/openai_gateway_grok_test.go +++ b/backend/internal/service/openai_gateway_grok_test.go @@ -2583,13 +2583,6 @@ func TestHandleGrokAccountUpstreamErrorTempUnschedulesNonRateLimitStates(t *test wantMinCooldown: 2*time.Minute - time.Second, wantMaxCooldown: 2*time.Minute + time.Second, }, - { - name: "method not allowed", - status: http.StatusMethodNotAllowed, - wantReason: "grok endpoint not supported (405)", - wantMinCooldown: 30*time.Minute - time.Second, - wantMaxCooldown: 30*time.Minute + time.Second, - }, } for _, tt := range tests {