task_id: task_create_page_login entity_id: page_login generated_at: '2025-12-18T15:16:50.289459' workflow_version: v001 target: type: page definition: id: page_login path: /login title: Login description: User login page data_needs: - api_id: api_login purpose: Authenticate user on_load: false components: - component_auth_form auth: required: false redirect_if_authenticated: / related: models: [] apis: - id: api_login definition: &id002 id: api_login method: POST path: /api/auth/login description: Login with email and password request_body: email: string password: string responses: - status: 200 description: Login successful schema: user: id: uuid email: string name: string role: string token: string - status: 401 description: Invalid credentials schema: error: string auth: required: false depends_on_models: - model_user components: - id: component_auth_form definition: &id001 id: component_auth_form name: AuthForm description: Reusable authentication form props: - name: mode type: enum[login, register, forgot] required: true state: - name: email type: string - name: password type: string - name: name type: string - name: role type: string events: - name: onSubmit payload: object uses_apis: - api_login - api_register - api_forgot_password uses_components: [] dependencies: entity_ids: - component_auth_form - api_login definitions: - id: component_auth_form type: component definition: *id001 - id: api_login type: api definition: *id002 files: to_create: - app/login/page.tsx reference: [] acceptance: - criterion: Page renders at /login verification: Navigate to /login - criterion: Data fetching works verification: Check network tab - criterion: Components render correctly verification: Visual inspection