import { queryParams, type RouteQueryOptions, type RouteDefinition, type RouteFormDefinition } from './../../wayfinder'
import liveChatD0d6fd from './live-chat'
import widget from './widget'
import apiTokens from './api-tokens'
import system from './system'
import branding from './branding'
import marketing from './marketing'
import privacy from './privacy'
/**
* @see \App\Http\Controllers\Admin\LiveChatSettingsController::liveChat
* @see app/Http/Controllers/Admin/LiveChatSettingsController.php:25
* @route '/app/settings/live-chat'
*/
export const liveChat = (options?: RouteQueryOptions): RouteDefinition<'get'> => ({
    url: liveChat.url(options),
    method: 'get',
})

liveChat.definition = {
    methods: ["get","head"],
    url: '/app/settings/live-chat',
} satisfies RouteDefinition<["get","head"]>

/**
* @see \App\Http\Controllers\Admin\LiveChatSettingsController::liveChat
* @see app/Http/Controllers/Admin/LiveChatSettingsController.php:25
* @route '/app/settings/live-chat'
*/
liveChat.url = (options?: RouteQueryOptions) => {
    return liveChat.definition.url + queryParams(options)
}

/**
* @see \App\Http\Controllers\Admin\LiveChatSettingsController::liveChat
* @see app/Http/Controllers/Admin/LiveChatSettingsController.php:25
* @route '/app/settings/live-chat'
*/
liveChat.get = (options?: RouteQueryOptions): RouteDefinition<'get'> => ({
    url: liveChat.url(options),
    method: 'get',
})

/**
* @see \App\Http\Controllers\Admin\LiveChatSettingsController::liveChat
* @see app/Http/Controllers/Admin/LiveChatSettingsController.php:25
* @route '/app/settings/live-chat'
*/
liveChat.head = (options?: RouteQueryOptions): RouteDefinition<'head'> => ({
    url: liveChat.url(options),
    method: 'head',
})

/**
* @see \App\Http\Controllers\Admin\LiveChatSettingsController::liveChat
* @see app/Http/Controllers/Admin/LiveChatSettingsController.php:25
* @route '/app/settings/live-chat'
*/
const liveChatForm = (options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
    action: liveChat.url(options),
    method: 'get',
})

/**
* @see \App\Http\Controllers\Admin\LiveChatSettingsController::liveChat
* @see app/Http/Controllers/Admin/LiveChatSettingsController.php:25
* @route '/app/settings/live-chat'
*/
liveChatForm.get = (options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
    action: liveChat.url(options),
    method: 'get',
})

/**
* @see \App\Http\Controllers\Admin\LiveChatSettingsController::liveChat
* @see app/Http/Controllers/Admin/LiveChatSettingsController.php:25
* @route '/app/settings/live-chat'
*/
liveChatForm.head = (options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
    action: liveChat.url({
        [options?.mergeQuery ? 'mergeQuery' : 'query']: {
            _method: 'HEAD',
            ...(options?.query ?? options?.mergeQuery ?? {}),
        }
    }),
    method: 'get',
})

liveChat.form = liveChatForm

const settings = {
    liveChat: Object.assign(liveChat, liveChatD0d6fd),
    widget: Object.assign(widget, widget),
    apiTokens: Object.assign(apiTokens, apiTokens),
    system: Object.assign(system, system),
    branding: Object.assign(branding, branding),
    marketing: Object.assign(marketing, marketing),
    privacy: Object.assign(privacy, privacy),
}

export default settings