@opengeni/api-router 0.21.7 → 0.21.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/app.js CHANGED
@@ -22,7 +22,7 @@ import {
22
22
  validateToolRefs,
23
23
  withDefaultEnabledCapabilityMcpTools,
24
24
  workflowIdForSession
25
- } from "./chunk-RIFVFI3J.js";
25
+ } from "./chunk-BESOWOUQ.js";
26
26
  export {
27
27
  API_MAX_REQUEST_BODY_BYTES,
28
28
  allowedCorsOrigin,
@@ -2200,8 +2200,12 @@ function socialProviderFetch(deps, url, init, label) {
2200
2200
  function socialOAuthClientFor(settings, provider) {
2201
2201
  const configured = parseSocialOauthClientsJson(settings.socialOauthClientsJson)[provider];
2202
2202
  if (!configured) {
2203
- throw new HTTPException4(503, {
2204
- message: `social provider ${provider} requires an operator OAuth app in OPENGENI_SOCIAL_OAUTH_CLIENTS_JSON`
2203
+ const providerLabel = provider === "x" ? "X" : "Reddit";
2204
+ throw new ApiHttpError(503, {
2205
+ code: "upstream_unavailable",
2206
+ message: `${providerLabel} connection is not configured. An operator must add ${providerLabel} OAuth credentials to OPENGENI_SOCIAL_OAUTH_CLIENTS_JSON.`,
2207
+ retryable: false,
2208
+ details: { oauthReason: "operator_oauth_app_missing", provider }
2205
2209
  });
2206
2210
  }
2207
2211
  return configured;
@@ -26543,4 +26547,4 @@ export {
26543
26547
  withDefaultEnabledCapabilityMcpTools,
26544
26548
  workflowIdForSession2 as workflowIdForSession
26545
26549
  };
26546
- //# sourceMappingURL=chunk-RIFVFI3J.js.map
26550
+ //# sourceMappingURL=chunk-BESOWOUQ.js.map