본문으로 바로가기 본문 바로가기
WIKI 기술 지식 베이스

jq 정책 구성 참조

원문 보기 위키 갱신

jq 정책 구성 참조 (jq Policy Configuration Reference)

이 문서는 Kong의 jq 정책에서 사용하는 구성 옵션을 JSON 스키마 형식으로 정리한 참조 자료예요. 요청과 응답 본문을 변환하는 jq 프로그램과 그 옵션, 적용할 미디어 타입이나 상태 코드 조건을 설정하는 방법을 설명해요. 각 필드의 기본값과 제약 조건도 함께 확인할 수 있어요.

출처: 문서

본문

{
  "properties": {
    "config": {
      "type": "object",
      "properties": {
        "response_jq_program": {
          "type": "string"
        },
        "response_jq_program_options": {
          "type": "object",
          "properties": {
            "compact_output": {
              "type": "boolean",
              "default": true
            },
            "raw_output": {
              "type": "boolean",
              "default": false
            },
            "join_output": {
              "type": "boolean",
              "default": false
            },
            "ascii_output": {
              "type": "boolean",
              "default": false
            },
            "sort_keys": {
              "type": "boolean",
              "default": false
            }
          },
          "default": {}
        },
        "response_if_media_type": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": [
            "application/json"
          ]
        },
        "response_if_status_code": {
          "type": "array",
          "items": {
            "type": "integer",
            "maximum": 599,
            "minimum": 100
          },
          "default": [
            200
          ]
        },
        "request_jq_program": {
          "type": "string"
        },
        "request_jq_program_options": {
          "type": "object",
          "properties": {
            "compact_output": {
              "type": "boolean",
              "default": true
            },
            "raw_output": {
              "type": "boolean",
              "default": false
            },
            "join_output": {
              "type": "boolean",
              "default": false
            },
            "ascii_output": {
              "type": "boolean",
              "default": false
            },
            "sort_keys": {
              "type": "boolean",
              "default": false
            }
          },
          "default": {}
        },
        "request_if_media_type": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": [
            "application/json"
          ]
        }
      }
    }
  }
}

관련 리소스

더 알아보기 (Learn more)