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

# Deny Device Authorization

> Deny a pending device authorization. The polling client stops with an error.



## OpenAPI

````yaml /openapi.json post /v1/agent-auth/device-authorizations/{userCode}/deny
openapi: 3.1.0
info:
  title: Korve API
  version: 0.1.0
  description: >-
    Typed control plane for deploying applications and explicitly provisioning
    their managed infrastructure.
servers:
  - url: https://api.korve.dev
security: []
paths:
  /v1/agent-auth/device-authorizations/{userCode}/deny:
    post:
      tags:
        - agentAuth
      summary: Deny Device Authorization
      description: >-
        Deny a pending device authorization. The polling client stops with an
        error.
      operationId: agentAuth.denyDeviceAuthorization
      parameters:
        - name: userCode
          in: path
          required: true
          schema:
            type: string
            pattern: ^[BCDFGHJKLMNPQRSTVWXZ]{4}-[BCDFGHJKLMNPQRSTVWXZ]{4}$
            maxLength: 9
            description: >-
              Human-entered pairing code in XXXX-XXXX form, from an unambiguous
              alphabet.
      requestBody:
        required: true
        x-korve-max-bytes: 1048576
        content:
          application/json:
            schema:
              type: object
              additionalProperties: false
      responses:
        '200':
          description: Device authorization denied.
          content:
            application/json:
              schema:
                type: object
                properties:
                  denied:
                    type: boolean
                    enum:
                      - true
                required:
                  - denied
        '404':
          description: Unknown, expired, approved, denied, or consumed device code.
      security:
        - session: []
components:
  securitySchemes:
    session:
      type: apiKey
      in: cookie
      name: korve.session_token

````