import { defineModule, defineRoute } from "../../shared/define-module"
import type {
  ActionsGetResponse,
  ActionsPutRequest,
  ActionsPutResponse,
} from "./types"

/**
 * Actions module definition - User automation rules
 */
export const actionsModule = defineModule({
  name: "actions",
  prefix: "/actions",
  routes: {
    // Get user actions/automation rules
    get: defineRoute<never, ActionsGetResponse>("GET", "/"),

    // Update user actions/automation rules
    put: defineRoute<ActionsPutRequest, ActionsPutResponse>("PUT", "/"),
  },
})

// Export the API type
export type ActionsAPI = typeof actionsModule.api
