> ## Documentation Index
> Fetch the complete documentation index at: https://docs.switchyard.run/llms.txt
> Use this file to discover all available pages before exploring further.

# Clock in or out

> Perform a clock in or clock out action via Deputy



## OpenAPI

````yaml api-reference/v1/openapi.yaml post /v1/auth/clock
openapi: 3.1.0
info:
  title: Goods API
  version: 1.0.0
  description: >-
    API for Goods grocery operations - scanner app, admin dashboard, and
    customer features
  contact:
    name: Goods Team
    url: https://goods.app
servers:
  - url: http://localhost:3000
    description: Local development
  - url: https://dev.api.switchyard.run
    description: Development
  - url: https://api.switchyard.run
    description: Production
security: []
tags:
  - name: v1
    description: API v1 - unified domain-based endpoints
  - name: Scanner
    description: Scanner app endpoints for drivers and pickers
  - name: Sweeps
    description: Sweep management - retail store pickup operations
  - name: RFC Picks
    description: Ready-for-checkout picking operations
  - name: Inventory
    description: Inventory management and barcode lookup
  - name: Admin
    description: Admin dashboard endpoints
  - name: Orders
    description: Order management
  - name: Products
    description: Product catalog management
  - name: Notifications
    description: Push, email, SMS, and Slack notification management
paths:
  /v1/auth/clock:
    post:
      tags:
        - Auth
      summary: Clock in or out
      description: Perform a clock in or clock out action via Deputy
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                action:
                  type: string
                  enum:
                    - clock_in
                    - clock_out
                staff_id:
                  type: string
                  format: uuid
              required:
                - action
      responses:
        '200':
          description: Clock action successful
          content:
            application/json:
              schema:
                anyOf:
                  - type: object
                    properties:
                      success:
                        type: boolean
                      action:
                        type: string
                        example: clock_in
                      timesheet_id:
                        type: number
                      start_time:
                        type: string
                        format: date-time
                      operational_unit_id:
                        type: number
                    required:
                      - success
                      - action
                      - timesheet_id
                      - start_time
                      - operational_unit_id
                  - type: object
                    properties:
                      success:
                        type: boolean
                      action:
                        type: string
                        example: clock_out
                      timesheet_id:
                        type: number
                      total_time:
                        type: number
                    required:
                      - success
                      - action
                      - timesheet_id
        '400':
          description: Clock action failed - validation error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  message:
                    type: string
                  elapsed_minutes:
                    type: number
                  minimum_minutes:
                    type: number
                required:
                  - error
        '404':
          description: Staff not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  message:
                    type: string
                  elapsed_minutes:
                    type: number
                  minimum_minutes:
                    type: number
                required:
                  - error
        '500':
          description: Server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  message:
                    type: string
                  elapsed_minutes:
                    type: number
                  minimum_minutes:
                    type: number
                required:
                  - error
        '503':
          description: Clock service not configured
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  message:
                    type: string
                  elapsed_minutes:
                    type: number
                  minimum_minutes:
                    type: number
                required:
                  - error

````