- Upgraded fastify from 4.x to 5.x to fix CVE-2026-25223 (HIGH severity)
- Updated all OpenTelemetry packages to latest versions
- Updated json-schema-to-typescript to fix deprecated dependency warnings
- Logging of requests, responses and errors has been improved to include the collection/operation name if available (#51, #54)
- Added support for automatically returning compressed responses using gzip or deflate (#47)
- All OpenTelemetry trace spans are now annotated with the SDK version (
resource.service.version) and the connector name (resource.service.connector.name) and version (resource.service.connector.version). The connector name and version can be passed toinitTelemetryor set at runtime usingHASURA_CONNECTOR_NAMEandHASURA_CONNECTOR_VERSIONenvironment variables. (#48)
- Increased
bodyLimitfrom 1mb to 30mb (#44)
Breaking changes since v7.0.0 (#39, #40, #42, #43):
- Updated to support v0.2.0 of the NDC Spec. This is a very large update which adds new features and some breaking changes.
- If the
X-Hasura-NDC-Versionheader is sent, the SDK will validate that the connector supports the incoming request's version and reject it if it does not. If no header is sent, no action is taken.
- Updated to support the latest release candidate (rc.3) of v0.2.0 of the NDC Spec (#42)
- Updated to support v0.2.0 of the NDC Spec. This is a very large update which adds new features and some breaking changes.
- If the
X-Hasura-NDC-Versionheader is sent, the SDK will validate that the connector supports the incoming request's version and reject it if it does not. If no header is sent, no action is taken.
- Added support for exporting OpenTelemetry traces and metrics over GRPC. A new environment variable
OTEL_EXPORTER_OTLP_PROTOCOLlets you switch betweenhttp/protobufandgrpc.- Breaking change: the default OpenTelemetry exporter has changed from
http/protobufsending tohttp://localhost:4318togrpcsending tohttp://localhost:4317. To return to the old defaults, set the following environment variables:OTEL_EXPORTER_OTLP_PROTOCOL="http/protobuf"OTEL_EXPORTER_OTLP_ENDPOINT="http://localhost:4318"
- Breaking change: the default OpenTelemetry exporter has changed from
- Updated to support v0.1.6 of the NDC Spec (#37)
- Support for querying nested collections inside an EXISTS expression in a predicate
Breaking changes (#36):
Connector.healthCheckhas been removed and replaced withConnector.getHealthReadiness, which only returns whether the connector is able to accept requests, not whether any underlying connections to data sources actually work.- The
/healthendpoint is now unauthorized, allowing healthchecks to be performed without authorization. Connector.getCapabilitiesnow returnsCapabilitiesinstead ofCapabilitiesResponse. The SDK will now take care of adding the correct NDC version to theCapabilitieson behalf of the connector.
- The connector now listens on both ipv4 and ipv6 interfaces by default. This can be configured by using the
HASURA_CONNECTOR_HOSTenvironment variable, which sets the host the web server listens on. (#34) - Updated to support v0.1.5 of the NDC Spec (#35)
- There are no real changes in this version; it is a version number-only change
- Updated to support v0.1.4 of the NDC Spec (#33)
- Support for aggregates over nested fields
- Updated to support v0.1.3 of the NDC Spec (#32)
- Breaking change: new
nested_fieldsproperty onQueryCapabilities; set it to{}to retain previous v0.1.2 semantics and not support new v0.1.3 capabilities. - Support field arguments
- Support filtering and ordering by nested fields
- Added a
bigintegertype representation
- Breaking change: new
- Use
prom-clientto implement the metrics endpoint (#29) - Allow any error code in custom HTTP responses (#30)
- Updated to support v0.1.2 of the NDC Spec
- More precise type representations of scalar types were added and the general numeric ones were deprecated (
numberandinteger)
- More precise type representations of scalar types were added and the general numeric ones were deprecated (
- Updated to support v0.1.1 of the NDC Spec
- A more precise definition of equality operators
- Scalar types can now specify a representation, including an enum representation
- Add
mainandtypesproperties to thepackage.jsonto enablenode10module resolution to be used by projects using legacy TypeScript compiler settings
- OpenTelemetry spans are now attributed with
internal.visibility: "user"so that they show up in the Hasura Console @hasura/ndc-sdk-typescript/instrumentationnow exportswithActiveSpanto wrap a span around a function andwithInternalActiveSpanwhich does the same but without theinternal.visibility: "user"attribute.- Automatic OpenTelemetry instrumentation for fetch requests has been added
- Add OpenTelemetry support
- Set env var
OTEL_EXPORTER_OTLP_ENDPOINTto the endpoint to send OpenTelemetry to OTEL_SERVICE_NAMEoverrides the service name- Command line arguments
--otlp-endpointand--service-namehave been removed in favour of the environment variables - Import
@hasura/ndc-sdk-typescript/instrumentationto useinitTelemetryto initialize OpenTelemetry earlier in your startup, if necessary
- Set env var
- Add OpenTelemetry support
- Set env var
OTEL_EXPORTER_OTLP_ENDPOINTto the endpoint to send OpenTelemetry to OTEL_SERVICE_NAMEoverrides the service name- Command line arguments
--otlp_endpointand--service-namehave been removed in favour of the environment variables - Import
@hasura/ndc-sdk-typescript/instrumentationto useinitTelemetryto initialize OpenTelemetry earlier in your startup, if necessary
- Set env var
Breaking change: support for the Connector Deployment Spec.
- The connector configuration server has been removed
- The way configuration is handled on
Connectorinterface has changedgetRawConfigurationSchema,makeEmptyConfiguration,updateConfigurationhave been removed.parseConfiguationreplacesvalidateRawConfiguration, and is given the directory path in which the connector's configuration files can be found- The
RawConfigurationtype parameter has been removed
- The default port has changed from 8100 to 8080
- The command line arguments passed to the
servecommand have changed:- The
--configurationargument now takes the connector's configuration directory. Its associated environment variable is nowHASURA_CONFIGURATION_DIRECTORY - The
--otlp_endpointargument has been renamed to--otlp-endpointand its environment variable is nowOTEL_EXPORTER_OTLP_ENDPOINT - The
PORTenvironment variable has changed toHASURA_CONNECTOR_PORT - The
SERVICE_TOKEN_SECRETenvironment variable has changed toHASURA_SERVICE_TOKEN_SECRET - The
LOG_LEVELenvironment variable has changed toHASURA_LOG_LEVEL - The
PRETTY_PRINT_LOGSenvironment variable has changed toHASURA_PRETTY_PRINT_LOGS
- The
Breaking change: support for the v0.1.0-rc.15 of NDC Spec.
- The mutation request/response format has changed.
MutationOperationfields are now defined as aNestedFieldMutationOperationResponsenow returns a single value rather than a rowset
Breaking change: support for the v0.1.0-rc.14 of NDC Spec.
- Function name formatting is now standard JavaScript
camelCase. NDC types used for wire-transmission match the spec (snake_cased). - Added nested field selections (
Field.fields) - Capabilities now only specifies a single supported version (
CapabilitiesResponse.version) Expression.whererenamed toExpression.predicatePathElement.predicateis now optional- Added Predicate types (new
predicateType.type) - Added mutation capability
- Comparison operators
- Changes to explain:
Connector.explainrenamed toConnector.queryExplainand endpoint moved from/explainto/query/explain.Connector.mutationExplainadded with endpoint/mutation/explain.explaincapability moved toquery.explain.mutation.explaincapability added.
ComparisonOperatorDefinitionnow hasequalandinas two standard definitions and custom operators can be defined. The equality operator is no longer required to be defined and must be explicitly defined.
- Add new
ConnectorErrortypes:UnprocessableContent: The request could not be handled because, while the request was well-formed, it was not semantically correct. For example, a value for a custom scalar type was provided, but with an incorrect typeBadGateway: The request could not be handled because an upstream service was unavailable or returned an unexpected response, e.g., a connection to a database server failed
- Generate TypeScript declaration maps for better "go to definition" tooling
get_serve_commandandget_serve_configuration_commandnow support creation without automatically starting servers. This allows usage in scenarios where a customized server startup is desired.
- added auth hook using secret token