AiAgentOnboardingController
in package
Table of Contents
Properties
Methods
- __construct() : mixed
- generateToken() : string
- Generate onboarding token
- show() : mixed
- Show the onboarding form
- submit() : mixed
- Handle form submission
- findOrCreateProfile() : AiAgentProfile
- Find or create profile for the given profileable
- sendSetupConfirmation() : void
- Send SMS confirmation that profile is set up
Properties
$smsService
protected
SmsService
$smsService
Methods
__construct()
public
__construct(SmsService $smsService) : mixed
Parameters
- $smsService : SmsService
generateToken()
Generate onboarding token
public
static generateToken(string $profileableType, int $profileableId) : string
Parameters
- $profileableType : string
- $profileableId : int
Return values
stringshow()
Show the onboarding form
public
show(Request $request, string $token) : mixed
Parameters
- $request : Request
- $token : string
submit()
Handle form submission
public
submit(Request $request, string $token) : mixed
Parameters
- $request : Request
- $token : string
findOrCreateProfile()
Find or create profile for the given profileable
protected
findOrCreateProfile(string $type, int $id) : AiAgentProfile
Parameters
- $type : string
- $id : int
Return values
AiAgentProfilesendSetupConfirmation()
Send SMS confirmation that profile is set up
protected
sendSetupConfirmation(AiAgentProfile $profile) : void
Parameters
- $profile : AiAgentProfile