Skip to content
HALOWERK

Codewerk

sqlfluff

Runs sqlfluff 4.5.0 (MIT) from a hash-pinned private Python environment in an isolated child process without network: layout (LT), capitalisation (CP), aliasing (AL), ambiguity (AM), convention (CV), references (RF) and structure (ST) rules for ansi, postgres, mysql, bigquery, snowflake, tsql, sqlite, duckdb and 20 more dialects. Parse failures are returned as PRS entries with position. Templating is disabled (raw templater): Jinja/dbt placeholders are not rendered. With fix=true the SQL.

POST https://code.halowerk.com/v1/sqlfluff

Inputs

Fields of the published input schema
FieldTypeRequiredDescription
sqlstringYesSQL text (max. 256 KB).
dialectstringYesSQL dialect.
rulesarrayNoOnly these rule codes or groups (e.g. ["LT01", "CP01"] or ["layout"]); default all.
exclude_rulesarrayNoRule codes or groups to skip.
max_line_lengthintegerNoLine length limit for LT05 (default 80).
fixbooleanNoAlso return the SQL fixed by sqlfluff.
Show full input schema
{
  "type": "object",
  "additionalProperties": false,
  "required": [
    "sql",
    "dialect"
  ],
  "properties": {
    "sql": {
      "type": "string",
      "minLength": 1,
      "maxLength": 262144,
      "description": "SQL text (max. 256 KB)."
    },
    "dialect": {
      "type": "string",
      "enum": [
        "ansi",
        "athena",
        "bigquery",
        "clickhouse",
        "databricks",
        "db2",
        "doris",
        "duckdb",
        "exasol",
        "flink",
        "greenplum",
        "hive",
        "impala",
        "mariadb",
        "materialize",
        "mysql",
        "oracle",
        "postgres",
        "redshift",
        "snowflake",
        "soql",
        "sparksql",
        "sqlite",
        "starrocks",
        "teradata",
        "trino",
        "tsql",
        "vertica"
      ],
      "description": "SQL dialect."
    },
    "rules": {
      "type": "array",
      "maxItems": 80,
      "uniqueItems": true,
      "items": {
        "type": "string",
        "pattern": "^[A-Za-z]{2}[0-9]{2}$|^[a-z]+$"
      },
      "description": "Only these rule codes or groups (e.g. [\"LT01\", \"CP01\"] or [\"layout\"]); default all."
    },
    "exclude_rules": {
      "type": "array",
      "maxItems": 80,
      "uniqueItems": true,
      "items": {
        "type": "string",
        "pattern": "^[A-Za-z]{2}[0-9]{2}$|^[a-z]+$"
      },
      "description": "Rule codes or groups to skip."
    },
    "max_line_length": {
      "type": "integer",
      "minimum": 40,
      "maximum": 400,
      "description": "Line length limit for LT05 (default 80)."
    },
    "fix": {
      "type": "boolean",
      "default": false,
      "description": "Also return the SQL fixed by sqlfluff."
    }
  }
}

Open original schema

Published input example

{
  "sql": "select a,b from orders where id=1",
  "dialect": "postgres",
  "fix": true
}

Result & documentation

Machine-readable documentation of this hub

Source of this page: the published HALOWERK catalog. Updated: 2026-11-17 UTC.

More endpoints in this hub

All endpoints in this hub โ†’