only keep totp endpoint (#3704)
This commit is contained in:
@@ -54,7 +54,7 @@ STEP_PREFIX = "stp"
|
||||
TASK_GENERATION_PREFIX = "tg"
|
||||
TASK_PREFIX = "tsk"
|
||||
TASK_RUN_PREFIX = "tr"
|
||||
OTP_CODE_PREFIX = "otp"
|
||||
TOTP_CODE_PREFIX = "totp"
|
||||
USER_PREFIX = "u"
|
||||
WORKFLOW_PARAMETER_PREFIX = "wp"
|
||||
WORKFLOW_PERMANENT_ID_PREFIX = "wpid"
|
||||
@@ -169,9 +169,9 @@ def generate_ai_suggestion_id() -> str:
|
||||
return f"{AI_SUGGESTION_PREFIX}_{int_id}"
|
||||
|
||||
|
||||
def generate_otp_code_id() -> str:
|
||||
def generate_totp_code_id() -> str:
|
||||
int_id = generate_id()
|
||||
return f"{OTP_CODE_PREFIX}_{int_id}"
|
||||
return f"{TOTP_CODE_PREFIX}_{int_id}"
|
||||
|
||||
|
||||
def generate_action_id() -> str:
|
||||
|
||||
@@ -35,7 +35,6 @@ from skyvern.forge.sdk.db.id import (
|
||||
generate_org_id,
|
||||
generate_organization_auth_token_id,
|
||||
generate_organization_bitwarden_collection_id,
|
||||
generate_otp_code_id,
|
||||
generate_output_parameter_id,
|
||||
generate_persistent_browser_session_id,
|
||||
generate_script_block_id,
|
||||
@@ -48,6 +47,7 @@ from skyvern.forge.sdk.db.id import (
|
||||
generate_task_run_id,
|
||||
generate_task_v2_id,
|
||||
generate_thought_id,
|
||||
generate_totp_code_id,
|
||||
generate_workflow_id,
|
||||
generate_workflow_parameter_id,
|
||||
generate_workflow_permanent_id,
|
||||
@@ -584,7 +584,7 @@ class TOTPCodeModel(Base):
|
||||
Index("ix_totp_codes_otp_type", "organization_id", "otp_type"),
|
||||
)
|
||||
|
||||
totp_code_id = Column(String, primary_key=True, default=generate_otp_code_id)
|
||||
totp_code_id = Column(String, primary_key=True, default=generate_totp_code_id)
|
||||
totp_identifier = Column(String, nullable=False, index=True)
|
||||
organization_id = Column(String, ForeignKey("organizations.organization_id"))
|
||||
task_id = Column(String, ForeignKey("tasks.task_id"))
|
||||
|
||||
Reference in New Issue
Block a user