diff --git a/packages/backend-core/src/constants/misc.ts b/packages/backend-core/src/constants/misc.ts index 139bd7c0d3..aee099e10a 100644 --- a/packages/backend-core/src/constants/misc.ts +++ b/packages/backend-core/src/constants/misc.ts @@ -11,25 +11,7 @@ export enum Cookie { OIDC_CONFIG = "budibase:oidc:config", } -export enum Header { - API_KEY = "x-budibase-api-key", - LICENSE_KEY = "x-budibase-license-key", - API_VER = "x-budibase-api-version", - APP_ID = "x-budibase-app-id", - SESSION_ID = "x-budibase-session-id", - TYPE = "x-budibase-type", - PREVIEW_ROLE = "x-budibase-role", - TENANT_ID = "x-budibase-tenant-id", - VERIFICATION_CODE = "x-budibase-verification-code", - RETURN_VERIFICATION_CODE = "x-budibase-return-verification-code", - RESET_PASSWORD_CODE = "x-budibase-reset-password-code", - RETURN_RESET_PASSWORD_CODE = "x-budibase-return-reset-password-code", - TOKEN = "x-budibase-token", - CSRF_TOKEN = "x-csrf-token", - CORRELATION_ID = "x-budibase-correlation-id", - AUTHORIZATION = "authorization", - MIGRATING_APP = "x-budibase-migrating-app", -} +export { Header } from "@budibase/shared-core" export enum GlobalRole { OWNER = "owner", diff --git a/packages/shared-core/src/constants/api.ts b/packages/shared-core/src/constants/api.ts new file mode 100644 index 0000000000..d6633649e6 --- /dev/null +++ b/packages/shared-core/src/constants/api.ts @@ -0,0 +1,19 @@ +export enum Header { + API_KEY = "x-budibase-api-key", + LICENSE_KEY = "x-budibase-license-key", + API_VER = "x-budibase-api-version", + APP_ID = "x-budibase-app-id", + SESSION_ID = "x-budibase-session-id", + TYPE = "x-budibase-type", + PREVIEW_ROLE = "x-budibase-role", + TENANT_ID = "x-budibase-tenant-id", + VERIFICATION_CODE = "x-budibase-verification-code", + RETURN_VERIFICATION_CODE = "x-budibase-return-verification-code", + RESET_PASSWORD_CODE = "x-budibase-reset-password-code", + RETURN_RESET_PASSWORD_CODE = "x-budibase-return-reset-password-code", + TOKEN = "x-budibase-token", + CSRF_TOKEN = "x-csrf-token", + CORRELATION_ID = "x-budibase-correlation-id", + AUTHORIZATION = "authorization", + MIGRATING_APP = "x-budibase-migrating-app", +} diff --git a/packages/shared-core/src/constants.ts b/packages/shared-core/src/constants/index.ts similarity index 99% rename from packages/shared-core/src/constants.ts rename to packages/shared-core/src/constants/index.ts index 0787b8bed1..a23913dd11 100644 --- a/packages/shared-core/src/constants.ts +++ b/packages/shared-core/src/constants/index.ts @@ -1,3 +1,5 @@ +export * from "./api" + export const OperatorOptions = { Equals: { value: "equal",