@base44-preview/cli 0.0.50-pr.445.28459a0 → 0.0.50-pr.445.336b900

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/cli/index.js CHANGED
@@ -241789,16 +241789,15 @@ function hasAnyLoginMethod(config3) {
241789
241789
  var SOCIAL_PROVIDERS = {
241790
241790
  google: {
241791
241791
  field: "enableGoogleLogin",
241792
- label: "Google",
241793
241792
  customOAuth: {
241794
241793
  modeField: "googleOAuthMode",
241795
241794
  clientIdField: "googleOAuthClientId",
241796
241795
  secretKey: "google_oauth_client_secret"
241797
241796
  }
241798
241797
  },
241799
- microsoft: { field: "enableMicrosoftLogin", label: "Microsoft" },
241800
- facebook: { field: "enableFacebookLogin", label: "Facebook" },
241801
- apple: { field: "enableAppleLogin", label: "Apple" }
241798
+ microsoft: { field: "enableMicrosoftLogin" },
241799
+ facebook: { field: "enableFacebookLogin" },
241800
+ apple: { field: "enableAppleLogin" }
241802
241801
  };
241803
241802
  function toAuthConfigPayload(config3) {
241804
241803
  return {
@@ -242752,11 +242751,51 @@ var EntityAutomationSchema = AutomationBaseSchema.extend({
242752
242751
  entity_name: exports_external.string().min(1, "Entity name cannot be empty"),
242753
242752
  event_types: exports_external.array(exports_external.enum(["create", "update", "delete"])).min(1, "At least one event type is required")
242754
242753
  });
242754
+ var KnownConditionOperators = [
242755
+ "equals",
242756
+ "not_equals",
242757
+ "gt",
242758
+ "gte",
242759
+ "lt",
242760
+ "lte",
242761
+ "contains",
242762
+ "not_contains",
242763
+ "starts_with",
242764
+ "ends_with",
242765
+ "in_list",
242766
+ "not_in_list",
242767
+ "exists",
242768
+ "not_exists",
242769
+ "is_empty",
242770
+ "is_not_empty"
242771
+ ];
242772
+ var ConditionOperatorSchema = exports_external.union([
242773
+ exports_external.enum(KnownConditionOperators),
242774
+ exports_external.string().min(1)
242775
+ ]);
242776
+ var TriggerConditionSchema = exports_external.object({
242777
+ field: exports_external.string().min(1),
242778
+ operator: ConditionOperatorSchema,
242779
+ value: exports_external.unknown().nullable().optional()
242780
+ });
242781
+ var TriggerLogicSchema = exports_external.enum(["and", "or"]);
242782
+ var TriggerConditionGroupSchema = exports_external.lazy(() => exports_external.object({
242783
+ logic: TriggerLogicSchema.optional(),
242784
+ conditions: exports_external.array(exports_external.union([TriggerConditionSchema, TriggerConditionGroupSchema])).min(1)
242785
+ }));
242786
+ var ConnectorAutomationSchema = AutomationBaseSchema.extend({
242787
+ type: exports_external.literal("connector"),
242788
+ integration_type: IntegrationTypeSchema,
242789
+ events: exports_external.array(exports_external.string()),
242790
+ resource_id: exports_external.string().nullable().optional(),
242791
+ trigger_conditions: TriggerConditionGroupSchema.nullable().optional()
242792
+ });
242755
242793
  var AutomationSchema = exports_external.union([
242756
242794
  ScheduledOneTimeSchema,
242757
242795
  ScheduledCronSchema,
242758
242796
  ScheduledSimpleSchema,
242759
- EntityAutomationSchema
242797
+ EntityAutomationSchema,
242798
+ ConnectorAutomationSchema
242760
242799
  ]);
242761
242800
  var FunctionConfigSchema = exports_external.object({
242762
242801
  name: FunctionNameSchema,
@@ -250898,10 +250937,16 @@ function getAuthPushCommand() {
250898
250937
 
250899
250938
  // src/cli/commands/auth/social-login.ts
250900
250939
  import { dirname as dirname10, join as join15, resolve as resolve2 } from "node:path";
250940
+ var PROVIDER_LABELS = {
250941
+ google: "Google",
250942
+ microsoft: "Microsoft",
250943
+ facebook: "Facebook",
250944
+ apple: "Apple"
250945
+ };
250901
250946
  var VALID_PROVIDER_NAMES = Object.keys(SOCIAL_PROVIDERS);
250902
250947
  var PROVIDER_OAUTH_CLI = {
250903
250948
  google: {
250904
- envVar: "BASE44_GOOGLE_OAUTH_CLIENT_SECRET",
250949
+ envVar: "google_oauth_client_secret",
250905
250950
  promptMessage: "Enter Google OAuth client secret"
250906
250951
  }
250907
250952
  };
@@ -250914,7 +250959,7 @@ function hasCustomOAuthOptions(options) {
250914
250959
  async function socialLoginAction({ log, isNonInteractive, runTask: runTask2 }, provider, action, options) {
250915
250960
  const shouldEnable = action === "enable";
250916
250961
  const providerInfo = SOCIAL_PROVIDERS[provider];
250917
- const label = providerInfo.label;
250962
+ const label = PROVIDER_LABELS[provider];
250918
250963
  const hasOAuthOptions = hasCustomOAuthOptions(options);
250919
250964
  if (hasOAuthOptions && !providerInfo.customOAuth) {
250920
250965
  throw new InvalidInputError(`Custom OAuth options are only supported for providers with custom OAuth (e.g., google). Use: base44 auth social-login ${provider} ${action}`);
@@ -250975,7 +251020,7 @@ async function socialLoginAction({ log, isNonInteractive, runTask: runTask2 }, p
250975
251020
  let outroMessage = `${label} login ${newStatus}${oauthNote} in local config. Run \`base44 auth push\` or \`base44 deploy\` to apply.`;
250976
251021
  if (useCustomOAuth && !clientSecret) {
250977
251022
  outroMessage += `
250978
- Remember to push the client secret separately: base44 secrets set --env-file <path>`;
251023
+ Remember to push the client secret separately: base44 auth social-login ${provider} enable --client-id ${options.clientId} --env-file <path>`;
250979
251024
  }
250980
251025
  return { outroMessage };
250981
251026
  }
@@ -260418,4 +260463,4 @@ export {
260418
260463
  CLIExitError
260419
260464
  };
260420
260465
 
260421
- //# debugId=A5870B4B3C54D78864756E2164756E21
260466
+ //# debugId=98345FFC5B7D0AE164756E2164756E21