// This file is auto-generated by @hey-api/openapi-ts

import { oc } from '@orpc/contract'
import * as z from 'zod'
import { zGetInitResponse, zPostInitBody, zPostInitResponse } from './zod.gen'

/**
 * Get initialization validation status.
 */
export const get = oc
  .route({
    inputStructure: 'detailed',
    method: 'GET',
    operationId: 'getInit',
    path: '/init',
    summary: 'Get initialization validation status.',
    tags: ['console'],
  })
  .output(zGetInitResponse)

/**
 * Validate initialization password.
 */
export const post = oc
  .route({
    inputStructure: 'detailed',
    method: 'POST',
    operationId: 'postInit',
    path: '/init',
    successStatus: 201,
    summary: 'Validate initialization password.',
    tags: ['console'],
  })
  .input(z.object({ body: zPostInitBody }))
  .output(zPostInitResponse)

export const init = {
  get,
  post,
}

export const contract = {
  init,
}
