---
title: "DebugSession"
url: "https://nov18-dev.movespot.fyi/apis/konnect-dolly-apis-dev-1/versions/4ba55f2d-e3a2-486c-a018-16faa4e1afe4/schemas/DebugSession"
---

> Full API specification: https://nov18-dev.movespot.fyi/apis/konnect-dolly-apis-dev-1/versions/4ba55f2d-e3a2-486c-a018-16faa4e1afe4.md

# DebugSession

## OpenAPI definition

```yaml
openapi: 3.0.3
info:
  title: Konnect Dolly APIs
  version: 1.0.0
servers:
  - url: https://us.api.konghq.com/v1
    description: United-States Production region
  - url: https://eu.api.konghq.com/v1
    description: Europe Production region
  - url: https://au.api.konghq.com/v1
    description: Australia Production region
  - url: https://me.api.konghq.com/v1
    description: Middle-East Production region
  - url: https://in.api.konghq.com/v1
    description: India Production region
  - url: https://sg.api.konghq.com/v1
    description: Singapore Production region
components:
  schemas:
    UUID:
      description: Contains a unique identifier used for this resource.
      type: string
      format: uuid
      example: 5f9fd312-a987-4628-b4c5-bb4f4fddd5f7
      readOnly: true
    CaptureContentType:
      type: string
      enum:
        - headers
        - body
    CaptureLogType:
      type: string
      enum:
        - error
        - access
    CaptureProfileInfo:
      description: CaptureProfile contains the information around the profile that
        needs to be captured. Currently supports CPU profiling, with potential
        for memory profiling in the future.
      type: object
      properties:
        cpu:
          $ref: "#/components/schemas/CPUProfile"
    CreatedAt:
      description: An ISO-8601 timestamp representation of entity creation date.
      type: string
      format: date-time
      example: 2022-11-04T20:10:06.927Z
      readOnly: true
    UpdatedAt:
      description: An ISO-8601 timestamp representation of entity update date.
      type: string
      format: date-time
      example: 2022-11-04T20:10:06.927Z
      readOnly: true
    PayloadSanitizationConfig:
      description: Configuration for sanitizing sensitive data in captured payloads
      type: object
      properties:
        user_defined_rules:
          $ref: "#/components/schemas/UserDefinedRules"
    CPUProfile:
      description: CPUProfile contains parameters for cpu profile collection
      type: object
      properties:
        mode:
          description: The mode of cpu profile
          type: string
          example: time
          enum:
            - time
            - instruction
        sampling_interval:
          description: The interval for sampling. If the mode is 'time', this value is in
            microseconds. If the mode is 'instruction', this value is the step
            count.
          type: integer
          format: int64
          example: 1000
      required:
        - mode
    UserDefinedRules:
      description: User-defined payload sanitization rules
      type: object
      properties:
        headers:
          description: Rules for sanitizing HTTP headers
          type: array
          items:
            $ref: "#/components/schemas/HeaderSanitizationRule"
        body:
          description: Rules for sanitizing request/response body content
          type: array
          items:
            $ref: "#/components/schemas/BodySanitizationRule"
    HeaderSanitizationRule:
      type: object
      properties:
        name:
          description: Optional identifier for this rule
          type: string
          example: api-key
        header_name:
          description: HTTP header name to sanitize (case-insensitive)
          type: string
          example: auth-token
        scope:
          $ref: "#/components/schemas/SanitizationScope"
        action:
          $ref: "#/components/schemas/SanitizationAction"
      required:
        - header_name
        - scope
        - action
    BodySanitizationRule:
      type: object
      properties:
        name:
          description: Optional identifier for this rule
          type: string
          example: user-id
        strategy:
          $ref: "#/components/schemas/BodySanitizationStrategy"
        scope:
          $ref: "#/components/schemas/SanitizationScope"
        action:
          $ref: "#/components/schemas/SanitizationAction"
      required:
        - strategy
        - scope
        - action
    SanitizationScope:
      description: Where the rule applies
      type: array
      items:
        type: string
        enum:
          - request
          - response
      default:
        - request
        - response
    SanitizationAction:
      description: |
        - mask: Replace with "******"
      type: string
      default: mask
      enum:
        - mask
    BodySanitizationStrategy:
      description: Strategy for body content sanitization.
      oneOf:
        - $ref: "#/components/schemas/JsonPathStrategy"
        - $ref: "#/components/schemas/RegexStrategy"
    JsonPathStrategy:
      description: Strategy using JSONPath expression to locate content for sanitization.
      type: object
      properties:
        json_path:
          $ref: "#/components/schemas/JsonPathExpression"
      additionalProperties: false
      required:
        - json_path
    RegexStrategy:
      description: Strategy using regex pattern to locate content for sanitization.
      type: object
      properties:
        regex:
          $ref: "#/components/schemas/RegexPattern"
      additionalProperties: false
      required:
        - regex
    JsonPathExpression:
      description: JSONPath expression to locate the value.
      type: string
      example: $.user.email
    RegexPattern:
      description: Regex to match to locate the value.
      type: string
      format: regex
      example: \d{4}-\d{4}-\d{4}-\d{4}
    DebugSession:
      type: object
      properties:
        id:
          $ref: "#/components/schemas/UUID"
        name:
          description: The optional session name.
          type: string
        max_samples:
          description: The maximum amount of samples to collect per data plane.
          type: integer
          example: 10
          default: 200
          maximum: 200
          minimum: 1
        sampling_rule:
          description: An expression used to filter the requests to sample.
          type: string
          example: http.path == "/my-path"
          nullable: true
        duration_secs:
          description: The duration of the debug session in seconds.
          type: integer
          example: 300
          default: 300
          maximum: 1800
          minimum: 10
        capture_content:
          type: array
          items:
            $ref: "#/components/schemas/CaptureContentType"
        capture_log:
          type: array
          items:
            $ref: "#/components/schemas/CaptureLogType"
        capture_traces:
          description: Determines if Traces should be captured for this session.
          type: boolean
          example: true
          default: true
        capture_profile:
          $ref: "#/components/schemas/CaptureProfileInfo"
        started_at:
          description: An ISO-8601 timestamp representation of start date.
          type: string
          format: date-time
          example: 2024-11-04T20:10:06.927Z
          readOnly: true
        stopped_at:
          description: An ISO-8601 timestamp representation of stop date.
          type: string
          format: date-time
          example: 2022-11-04T20:10:06.927Z
          readOnly: true
        completed_at:
          description: An ISO-8601 timestamp representation of completion date.
          type: string
          format: date-time
          example: 2022-11-04T20:10:06.927Z
          readOnly: true
        timed_out:
          description: Determines whether the target did not respond in time before the
            sampling time elapsed.
          type: boolean
          readOnly: true
        created_at:
          $ref: "#/components/schemas/CreatedAt"
        updated_at:
          $ref: "#/components/schemas/UpdatedAt"
        targets:
          description: The data plane nodes to collect samples from.
          type: array
          items:
            type: string
            format: uuid
            example: 5f9fd312-a987-4628-b4c5-bb4f4fddd5f7
            description: Unique identifier of the data plane node.
          minItems: 1
        payload_sanitization:
          $ref: "#/components/schemas/PayloadSanitizationConfig"
```
